Hi I am trying toget my mail working on my classified site and I came across your post...
I am having a similar problem... everything works fine except my email .. when you click on the "Respond to Ad" link I get an error that says "email not sent"
I have had a couple of suggestions on how to fix it but when I ask further questions they go unanswered. This is my first asp site so I am very new to asp..
I was wondering if you could possibly answer a question for me....
I was told I could fix my email with the following code....
<
system.net>
<
mailSettings>
<
smtp deliveryMethod="Network" from="[email protected]">
<
network host="mailserver.domain.co.uk" port="25" userName="[email protected]" password="password" defaultCredentials="true"/>
</
smtp>
</
mailSettings>
</
system.net>
Then
Dim
maFrom As New MailAddress("[email protected]")
Dim
maTo As New MailAddress("[email protected]")
Dim
m
As New MailMessage(maFrom, maTo)
Dim smtp As New SmtpClient()
smtp.UseDefaultCredentials =
True
smtp.Send(m)
but where does the code from the word Then go? I don't think it goes in the web.config file.... and Is the first ewmail address the address that I want them to respond to? Where do I get the second email addresss?
Any help would be most appreciated?
thanks