2021-07-14 21:26:34 +10:00
|
|
|
@model PartyInvites.Models.GuestResponse
|
|
|
|
|
|
|
|
@{
|
|
|
|
Layout = null;
|
|
|
|
}
|
|
|
|
|
|
|
|
<!DOCTYPE html>
|
|
|
|
|
|
|
|
<html>
|
|
|
|
<head>
|
|
|
|
<title>Thanks</title>
|
|
|
|
</head>
|
|
|
|
<body>
|
2021-07-14 21:49:36 +10:00
|
|
|
@{
|
|
|
|
try
|
|
|
|
{
|
|
|
|
WebMail.SmtpServer = "smtp.example.com";
|
|
|
|
WebMail.SmtpPort = 586;
|
|
|
|
WebMail.EnableSsl = true;
|
|
|
|
WebMail.UserName = "mySmtpUsername";
|
|
|
|
WebMail.Password = "mySmtpPassword";
|
|
|
|
WebMail.From = "rsvp@example.com";
|
|
|
|
WebMail.Send("party-host@example.com", "RSVP Notification",
|
|
|
|
Model.Name + " is " + ((Model.WillAttend ?? false) ? "" : "not")
|
|
|
|
+ "attending");
|
|
|
|
}
|
|
|
|
catch (Exception)
|
|
|
|
{
|
|
|
|
@:<b>Sorry - we couldn't send the email to confirm your RSVP.</b>
|
|
|
|
}
|
|
|
|
}
|
2021-07-14 21:26:34 +10:00
|
|
|
<div>
|
|
|
|
<h1>Thank you, @Model.Name</h1>
|
|
|
|
@if (Model.WillAttend == true)
|
|
|
|
{
|
|
|
|
@:It's great that you're coming. The drinks are already in the fridge
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
@:Sorry to hear that you can't make it, but thanks for letting us know
|
|
|
|
}
|
|
|
|
|
|
|
|
</div>
|
|
|
|
</body>
|
|
|
|
</html>
|