Send mail with Smtp

Discussion in 'ASP.NET 2.0' started by tbener, Aug 23, 2006.

  1. hi,

    i'm trying to send mail from the web site.
    what host should i provide???
    on the Account Management it says:
    SMTP Server: smtp.mysite.com
    this is it?
    this is my code:

     
  2. You will have to use your 'localhost' to send mails from within your application.DASP does not let you use its smtp servers for this purpose to avoid any kind of abuse.Your site smtp servers are only used for your mail clients.

    Vikram

    DiscountASP.NET
    www.DiscountASP.NET
     
  3. Wait a second. Everything was working fine yesterday morning with emails...
    No change to code...

    Now out of the blue I am getting the following error...

     
  4. Bruce

    Bruce DiscountASP.NET Staff

    We always recommend our user to use "localhost" to relay email from the web application.

    Using SMTP.domain.com should never worked.

    Change


    <network host="smtp.mysite.com" userName=[email protected] password="myPassword"/>

    to


    <network host="localhost"/>

    Bruce

    DiscountASP.NET
    www.DiscountASP.NET
     
  5. Thanks Bruce.


    I tried that a few times and it didn't work. Got the same error.


    I used the NEW IIS Tools, Start/ Stop and Recycle App Pool and I was in business, it worked.


    Many thanks,
    BZ
     

Share This Page