Results 1 to 4 of 4

Thread: script for sending a form?

  1. #1
    Join Date
    Dec 2004
    Posts
    157
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default script for sending a form?

    i just figured out i need asp to send a form via email, i found one at w3schools:
    Code:
    <%
    Set myMail=CreateObject("CDO.Message")
    myMail.Subject="Sending email with CDO"
    myMail.From="mymail@mydomain.com"
    myMail.To="someone@somedomain.com"
    myMail.HTMLBody = "<h1>This is a message.</h1>" 
    myMail.Send
    %>
    would i chage HTMLBody to HTMLForm? or am i totally wrong?
    thanks..

  2. #2
    Join Date
    Dec 2004
    Location
    UK
    Posts
    2,358
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Before I start, I just want to point out that I've never touched ASP (nor do I have any intention to do so). I'm just looking through the MSDN documentation I have on my machine.

    Quote Originally Posted by darco9x2
    i just figured out i need asp to send a form via email, i found one at w3schools:
    Code:
    <%
    Set myMail=CreateObject("CDO.Message")
    myMail.Subject="Sending email with CDO"
    myMail.From="mymail@mydomain.com"
    myMail.To="someone@somedomain.com"
    myMail.HTMLBody = "<h1>This is a message.</h1>" 
    myMail.Send
    %>
    would i chage HTMLBody to HTMLForm? or am i totally wrong?
    thanks..
    No. There are two ways to include content in a message: the HTMLBody string, and the TextBody string. I think you can guess the difference between the two.

    Once you've received the request sent by the user, you should be able to use the Request.Form collection to access the data submitted, validate and format it, then assign it to one of the two previous properties.

    Incidentally, you could send a multi-part message which includes both HTML and a text alternative, but I'll leave you to look that up yourself.

    Mike

  3. #3
    Join Date
    Dec 2004
    Posts
    157
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    ok, i finally figured it out, and my host doesnt support asp, do you know a host that supports it?

  4. #4
    Join Date
    Dec 2004
    Location
    UK
    Posts
    2,358
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Quote Originally Posted by darco9x2
    ok, i finally figured it out, and my host doesnt support asp, do you know a host that supports it?
    I'm afraid I don't. As I said, I want nothing to do with ASP so I've never looked for a host that supports it.

    Mike

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •