Hi Dynamicweb,
We are having some trouble sending out html mails for ForgotPassword as we are using razor-templates.
Will it be possible to define the IsBodyHtml as a hidden input field or change the check below to test if the template name ends with "html" or "htm" then it should still work as intended for the old html-templates.
Friend Shared Function SendForgotPasswordEmail(userEmail As String, userName As String, password As String, isNewPwd As Boolean, recoveryUrl As String, emailTemplateFolder As String, Optional emailTagVals As Dictionary(Of String, String) = Nothing) As Boolean
Using myMail As New Mail.MailMessage()
Dim template As String = ""
Dim templateType As String = "txt"
If HttpContext.Current.Request.Form("ForgotPasswordMailTemplate") <> "" Then
template = HttpContext.Current.Request.Form("ForgotPasswordMailTemplate")
If InStr(template, ".htm", CompareMethod.Text) > 0 OrElse InStr(template, ".html", CompareMethod.Text) > 0 Then
templateType = "html"
End If
End If
If templateType = "txt" Then
myMail.IsBodyHtml = False
Else
myMail.IsBodyHtml = True
End If
Best regards, Anders