Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - RTE and ASPmail
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Forum LockedRTE and ASPmail

 Post Reply Post Reply
Author
Kocken View Drop Down
Newbie
Newbie
Avatar

Joined: 15 February 2005
Location: Sweden
Status: Offline
Points: 10
Post Options Post Options   Thanks (0) Thanks(0)   Quote Kocken Quote  Post ReplyReply Direct Link To This Post Topic: RTE and ASPmail
    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", "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>

Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post 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.


Edited by -boRg- - 15 February 2005 at 10:28am
Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post 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.
Back to Top
Kocken View Drop Down
Newbie
Newbie
Avatar

Joined: 15 February 2005
Location: Sweden
Status: Offline
Points: 10
Post Options Post Options   Thanks (0) Thanks(0)   Quote Kocken Quote  Post ReplyReply Direct Link To This Post 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
 
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.