Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - HTML Emails
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

HTML Emails

 Post Reply Post Reply Page  <123
Author
Misty View Drop Down
Senior Member
Senior Member
Avatar

Joined: 06 February 2002
Location: United States
Status: Offline
Points: 711
Post Options Post Options   Thanks (0) Thanks(0)   Quote Misty Quote  Post ReplyReply Direct Link To This Post Posted: 04 May 2004 at 3:10pm

I really appreciate Don's help. I have solved all of my problems. I wanted to share the code for the ASP page that sends out the email and the ASP Page that notifies users when someone has read their emails. This is very useful if you want to send HTML emails to your friends and would like to find out if they have read your email. You will need to create a form page and a page that adds the information to a database. The lines of code that are in red are significant.

Code for the page that sends out the email:

<% 

Option Explicit

'=========================================================== =====

' name: EmailSent.asp

' programmer: Misty Roberts

'Procedures:

' DrawPage()

'=========================================================== =====

      'Declare constants for a recordset that allows adding records

      Const adLockOptimistic = 3

      Const adOpenDynamic = 2

      dim sqlString

      dim connectionString, databaseName, Path

      dim rs

     

      Dim SubjectLine, Body, EmailNum

      dim SEmail, Sender, EmailBody

      dim Name, Msg, EmailAddr, Email

  

    'grab the variables from the form

    EmailNum = Request.QueryString("EmailID")

     

     

     'Set connection details

     Add your database connection details here

  

      sqlString = "Select * FROM Emails, Users"

      'Add WHERE Join clause

      sqlString = sqlString & " where Emails.EmailID=Users.EmailID"

      sqlString = sqlString & " and Emails.EmailID=" & EmailNum

     

      set rs = Server.CreateObject("ADODB.Recordset")

      rs.Open sqlString, connectionString, adOpenDynamic, adLockOptimistic

     

 

  

Back to Top
jb-- View Drop Down
Newbie
Newbie


Joined: 19 January 2005
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote jb-- Quote  Post ReplyReply Direct Link To This Post Posted: 27 January 2005 at 10:29am
Hi
 
Is it possible to send HTML emails using the code at ASP FAQ even though my server only supports Jmail?
 
Thanks
 
Jb
Back to Top
Misty View Drop Down
Senior Member
Senior Member
Avatar

Joined: 06 February 2002
Location: United States
Status: Offline
Points: 711
Post Options Post Options   Thanks (0) Thanks(0)   Quote Misty Quote  Post ReplyReply Direct Link To This Post Posted: 27 January 2005 at 1:18pm
What are you talking about? Please give me the exact URL for ASP FAQs. This is an old thread from last year. Did you want to be able to find out when people read your emails too?
Back to Top
dj air View Drop Down
Senior Member
Senior Member
Avatar

Joined: 05 April 2002
Location: United Kingdom
Status: Offline
Points: 3627
Post Options Post Options   Thanks (0) Thanks(0)   Quote dj air Quote  Post ReplyReply Direct Link To This Post Posted: 27 January 2005 at 1:45pm
please do not drag up old threads.

if you want to rel;ate to a thread please mention and link to the thread.
Back to Top
jb-- View Drop Down
Newbie
Newbie


Joined: 19 January 2005
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote jb-- Quote  Post ReplyReply Direct Link To This Post Posted: 27 January 2005 at 4:53pm
Sorry guys.  I'm just new to this forum.  What I am referring to is the first two messages in this topic.
 
Originally posted by dpyers dpyers wrote:

http://www.aspfaq.com/show.asp?id=2474

Bear in mind that the trend in email clients is to have html display turned off by default.

 
All I would simply like to do is send html emails from a form on a web page.  I have tried using the code on the ASP FAQ website as advised above but have been unable to get it working.  My server only supports Jmail - would this be the reason?  If so is there any other code I can use?
 
Thanks
 
Jb
Back to Top
dj air View Drop Down
Senior Member
Senior Member
Avatar

Joined: 05 April 2002
Location: United Kingdom
Status: Offline
Points: 3627
Post Options Post Options   Thanks (0) Thanks(0)   Quote dj air Quote  Post ReplyReply Direct Link To This Post Posted: 27 January 2005 at 5:17pm
if you use the Web wiz forum application look at the send_mail_function file..

ussually you need to set the body type to 1

1 ussually = html
0 = plain text.

also have a look at the mailing list for an example.
Back to Top
 Post Reply Post Reply Page  <123

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.