This commit is contained in:
2018-07-09 18:23:08 +00:00
parent 3d2e30f78b
commit 9b32a9c6ad
4 changed files with 121 additions and 7 deletions

View File

@@ -40,14 +40,15 @@ namespace contact.Pages
if(Contact.Company.ToLowerInvariant()!="google")
SendMail();
//TODO: go to a successful submit page or the root of the ayanova site
return RedirectToPage("Index");
//TODO: go to a successful submit page on the ayanova site
//return Redirect("/confirm.html");//sample quickie page I made up
return Redirect("https://ayanova.com");
}
private void SendMail()
{
var MessageBody = $"Name:\r\n{Contact.Name}\r\nCompany:\r\n{Contact.Company}\r\nMessage:\r\n{Contact.Message}";
var MessageBody = $"Name:\r\n{Contact.Name}\r\n\r\nCompany:\r\n{Contact.Company}\r\n\r\nMessage:\r\n{Contact.Message}";
//SEND TO US
using (var message = new MailMessage())