Print Page | Close Window

RTE and ASPmail

Printed From: Web Wiz Forums
Category: Web Wiz Web App Support Forums
Forum Name: Web Wiz Rich Text Editor (RTE)
Forum Description: Support forum for the Web Wiz Rich Text Editor (RTE).
URL: https://forums.webwiz.net/forum_posts.asp?TID=13817
Printed Date: 29 March 2026 at 2:47am
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: RTE and ASPmail
Posted By: Kocken
Subject: RTE and ASPmail
Date Posted: 15 February 2005 at 10:12am

Hi

Im using RTE 3 beta to let visitors send me a HTML message tru ASPmail, but the result shows up in plain text - like this.
 
<H1 align=center><FONT color=#009966>Hello&nbsp;Kalle </FONT></H1>
 
Any idéas?
Below is my sendmail.asp
 
TIA Bjorn
<html>
<head>
    <title>ASPSend mail example</title>
</head>

<body>

<%
Session("FromName") = Request("FromName")
Session("FromAddress") = Request("FromAddress")
Session("Subject") = Request("Subject")
Session("BodyText") = Request("BodyText")

Set Mailer = Server.CreateObject("SMTPsvg.Mailer")

    'Set variables
    Mailer.FromName = Session("FromName")
    Mailer.FromAddress = Session("FromAddress")
    Mailer.RemoteHost = "smtpmail.activeisp.com"
    Mailer.AddRecipient "Webmaster på Kocken.com", " mailto:bjorn@kocken.com - bjorn@kocken.com "
    Mailer.Subject = Session("Subject")
    Mailer.BodyText = Session("BodyText")
    Mailer.Charset = "2"

if Mailer.SendMail then
Response.Write "Mailet has been sent..."
else
Response.Write "Errorcode" & Mailer.Response
end if

'Abandoning session variables
Session.Abandon
%>

</body>
</html>




Replies:
Posted By: WebWiz-Bruce
Date Posted: 15 February 2005 at 10:27am
Before the line  Mailer.BodyText = Session("BodyText") add the following line:-

Mailer.ContentType = "text/HTML"

This will let your email client know that the email is in HTML format.


-------------
https://www.webwiz.net/web-wiz-forums/forum-hosting.htm" rel="nofollow - Web Wiz Forums Hosting
https://www.webwiz.net/web-hosting/windows-web-hosting.htm" rel="nofollow - ASP.NET Web Hosting


Posted By: WebWiz-Bruce
Date Posted: 15 February 2005 at 10:29am
One question though, why are you using session variables?

Not only does this require that the user sending the email have cookies enabled and it uses more server resources, but they are totally not needed.

-------------
https://www.webwiz.net/web-wiz-forums/forum-hosting.htm" rel="nofollow - Web Wiz Forums Hosting
https://www.webwiz.net/web-hosting/windows-web-hosting.htm" rel="nofollow - ASP.NET Web Hosting


Posted By: Kocken
Date Posted: 15 February 2005 at 11:05am
Thanks -boRg- for the quick response, now it works.
 
I´m just a newbie at programming and the sendmail.asp came from my webhost´s supportsite.
 
Now when this is solved i will incorporate it all over the site.
 
Love the RTE and the WebWiz Forum
 



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net