Browse Source

Changed contact 'from' to be from the user and set 'Sender' as support.

tags/3.0.0
Teknikode 1 year ago
parent
commit
9ea2967e02
1 changed files with 4 additions and 3 deletions
  1. 4
    3
      Teknik/Areas/Contact/Controllers/ContactController.cs

+ 4
- 3
Teknik/Areas/Contact/Controllers/ContactController.cs View File

@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
@@ -61,7 +61,8 @@ namespace Teknik.Areas.Contact.Controllers
client.Credentials = new System.Net.NetworkCredential(Config.ContactConfig.EmailAccount.Username, Config.ContactConfig.EmailAccount.Password);
client.Timeout = 5000;

MailMessage mail = new MailMessage(Config.ContactConfig.EmailAccount.EmailAddress, Config.SupportEmail);
MailMessage mail = new MailMessage(model.Email, Config.SupportEmail);
mail.Sender = new MailAddress(Config.ContactConfig.EmailAccount.EmailAddress);
mail.Subject = string.Format("Support Message from: {0} <{1}>", model.Name, model.Email);
mail.Body = string.Format(@"
New Support Message from: {0} <{1}>
@@ -89,4 +90,4 @@ Message: {3}", model.Name, model.Email, model.Subject, model.Message);
}
}
}
}
}

Loading…
Cancel
Save