homepage Welcome to WebmasterWorld Guest from 54.211.138.180
register, free tools, login, search, subscribe, help, library, announcements, recent posts, open posts,
Subscribe and Support WebmasterWorld
Visit PubCon.com
Home / Forums Index / WebmasterWorld / New To Web Development
Forum Library, Charter, Moderators: brotherhood of lan & mack

New To Web Development Forum

    
Email page
infernofiasco




msg:973868
 8:58 am on Oct 6, 2003 (gmt 0)

Iam tryin to create a page that will send an email straight from my server as an email.

E.g.

First Name < text box >
Surname < text box >
Email < text box >

etc

I think its the same as saving to my db, but also sending via a form. Whats the line to post it as an email in a form?

Cheers

 

BlueSky




msg:973869
 9:04 am on Oct 6, 2003 (gmt 0)

In which language?

infernofiasco




msg:973870
 9:09 am on Oct 6, 2003 (gmt 0)

sorry :)

vbscript (asp)

mcavill




msg:973871
 9:31 am on Oct 6, 2003 (gmt 0)

Try something like:

<%
Dim myMail
Set myMail = CreateObject("CDONTS.NewMail")
myMail.From = request("email")
myMail.To = "me@mydomain.com"
myMail.Subject = request("subject")
myMail.Body = request("message")
myMail.Send
Set myMail = Nothing

%>

thats assuming you post fields called email, subject and message to the page...

macrost




msg:973872
 11:58 am on Oct 7, 2003 (gmt 0)

And also that you have cdonts installed on your server...

Mac

mcavill




msg:973873
 12:15 pm on Oct 7, 2003 (gmt 0)

...yes that's fairly important for that code to work ;)

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / WebmasterWorld / New To Web Development
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About
© Webmaster World 1996-2014 all rights reserved