Wrox Programmer Forums
|
Classic ASP Basics For beginner programmers starting with "classic" ASP 3, pre-".NET." NOT for ASP.NET 1.0, 1.1, or 2.0
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old June 15th, 2005, 06:21 AM
Friend of Wrox
 
Join Date: May 2005
Posts: 189
Thanks: 0
Thanked 0 Times in 0 Posts
Default e-mail

Hei!

I want the visitorst at my web page to be able to sent e-mail from within the page. The e-mail are going to have some predefined text. The e-mail are going to be sent to a number of receivers (at the same time)from a check-list. The check-list is generated from my access-db. How?

__________________
Internet has become favorable with that tool...thank you Tim Berners-Lee!
 
Old June 17th, 2005, 01:16 PM
Registered User
 
Join Date: Apr 2004
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Need More Info Like what kind of server . But this will give you a start
Body = "PREDEFINED TEXT GOES HERE"

    Set objSendMail = CreateObject("CDO.Message")
    objSendMail.Subject = "Your Subject"
    'objSendMail.MailFormat = 0
    'objSendMail.BodyFormat = 0
    objSendMail.From = "you@yourdomain"
    objSendMail.htmlBody = Body

For each MailAddr in request.form(Your check list)

        Var = trim(rs("MailAddr"))

        objSendMail.To = var
        objSendMail.send
Next

set objSendMail = nothing


 
Old June 18th, 2005, 06:02 AM
Friend of Wrox
 
Join Date: May 2005
Posts: 189
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thank you casselj!

What a deft tool this http-network has been! My asp pages is stil on my own pc. I have installed the boundled ISS version. I am new to this, I am still reading Beginning ASP 3.0 (Wrox). My background is from within the printing-biz, from late 1970-tech to the first Mac in 1983. And the fantastic HyperCard. If you know to this? Sorry I did never use Mac at work.

What a digression!

PS. Is BODY ment t be a var or do you mean <BODY>!?

 
Old June 18th, 2005, 08:44 PM
Friend of Wrox
 
Join Date: Jan 2004
Posts: 1,870
Thanks: 12
Thanked 20 Times in 20 Posts
Send a message via AIM to mat41
Default

In that example body is a variable. Dont forget to place:
<% option explicit %>
at the very top of your page. This will prompt you to Dim variables - There are variables that need to be dimmed in the example above. What I have found to be the most trouble free mail method is cdoSys. Google cdoSys mail example for a working example including additional parameters not illustrated above.

Wind is your friend
Matt





Similar Threads
Thread Thread Starter Forum Replies Last Post
Send mail and attachments with PHP mail function Lofa Beginning PHP 1 June 2nd, 2008 03:24 PM
problems sending mail with java mail gandacuboy J2EE 2 December 20th, 2006 03:05 PM
Sending e-mail to different mail box! Calibus Classic ASP Databases 4 September 3rd, 2004 05:48 PM
Sending both text mail and HTML mail - CDONTS madhukp Classic ASP Basics 1 October 8th, 2003 01:05 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.