Click here to Skip to main content
15,886,199 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,
am working on e-commerce website, i have hosted the website using godaddy.
if the user try to contact email is not going, it working locally but it is not working when hoisted...
please any one out there help me...

here is my code in controller,
C#
public ActionResult Contact(Contact contact)
{
    if (ModelState.IsValid)
    {                
        MailMessage mail = new MailMessage();
        mail.To.Add("info@desidesigns.com.au");
        mail.From = new MailAddress("gagana@scudds.com");
        mail.Subject = contact.Subject;
        mail.Body = "Name=" + contact.Name + "\n" + "Emailaddress=" + contact.Emailaddress + "\n" + "Subject=" + contact.Subject + "\n" + "Enquiry=" + contact.Enquiry + "\n" + "Order No=" + contact.OrderNo;
        mail.IsBodyHtml = true;
        System.Net.Mail.SmtpClient smtp = new System.Net.Mail.SmtpClient();
        smtp.Host = "relay-hosting.secureserver.net";
        smtp.Port = 25;
        smtp.UseDefaultCredentials = true;
        smtp.Credentials = new System.Net.NetworkCredential("info@desidesigns.com.au", "admin@123");// Enter seders User name and password
        smtp.EnableSsl = true;                    
        smtp.Send(mail);
        return View(contact);
    }
    else
    {
        return View(contact);
    }
}

web config code,
XML
<system.net>
    <mailSettings>
      <smtp deliveryMethod="Network" from="info@desidesigns.com.au" >
        <network host="relay-hosting.secureserver.net" port="25" defaultCredentials="false" userName="info@desidesigns.com.au" password="admin@123" enableSsl="true"/>
      </smtp>


br mode="hold" />

Error ', getting is this..,
C#
A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 68.178.232.62:25
Posted
v2
Comments
Did you talk with Godaaay support?
Gagana Ranganath 11-Jun-14 2:18am    
no...
Please contact and see what they are suggesting you.
Gagana Ranganath 11-Jun-14 2:23am    
I had cal'd them they are not responding to the call, i have to solve this error right now, is there any other way to solve dis prob'm
Check this and make sure that you are on right track. :)

1 solution

Refer: GoDaddy Support[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900