sendMail.vb to allow contact form to connect to server + send mail

File Location: Httpdocs > site > plugins > sendMail.vb 

 

Find this in sendMail.vb #

 

Dim smtp As New SmtpClient(“relay-hosting.secureserver.net”)

 

If Len(txtURL.text) > 1 Then

Response.Redirect(“error”)

End If

 

Try

smtp.Credentials = New NetworkCredential(“DONOTREPLY@aaroofingfl.com”, “000215”)

smtp.Send(mail)

Response.Redirect(“thanks”)

Catch ehttp As System.Web.HttpException

Response.Redirect(“error”)

End Try

 

Replace with this… #

 

Dim smtp As New SmtpClient() ← Remove relay should just be ()

 

If Len(txtURL.text) > 1 Then

Response.Redirect(“error”)

End If

 

Try

smtp.Credentials = New _

Net.NetworkCredential(“Post Mark Relay Credentials”, “Post Mark Relay Credentials”) ← Replace Credentials with the post mark credentials

smtp.Port = 587

smtp.Host = “smtp.postmarkapp.com”

smtp.Send(mail)

Response.Redirect(“thanks”)

Catch ehttp As System.Web.HttpException

Response.Redirect(“error”)

End Try

What are your feelings