sending multiple formfields with cdonts

Results 1 to 2 of 2

Thread: sending multiple formfields with cdonts

  1. #1
    Join Date
    Dec 1969

    Default sending multiple formfields with cdonts

    Hi,<BR>I would like to make it possible to send the content of several textfields in a form to the BODY of e-mail adres.<BR><BR>Well, the mail is sent allright, but there is no content in the body of the message if I try to send multiple txtfields ( one txtfield works fine)<BR><BR>Please look at this piece of code, and if you know do respond:<BR><BR>&#060;%@LANGUAGE="VBSCRIPT"%&#062; <BR>&#060;%<BR> Option Explicit<BR> Dim objNewMail<BR>%&#062;<BR>&#060;!--#include file="" --&#062;<BR>&#060;%<BR> Set objNewMail = Server.CreateObject("CDONTS.NewMail")<BR> objNewMail.From = "website"<BR> objNewMail.To = "emailadres"<BR> objNewMail.Subject = "response from website."<BR>---&#062;objNewMail.Body = request.form("frst_txtfield, scnd_txtfield")&#060;--<BR> objNewMail.BodyFormat = CdoBodyFormatText<BR> objNewMail.MailFormat = CdoMailFormatText<BR> objNewMail.Importance = CdoNormal<BR> objNewMail.Send<BR> Set objNewMail = Nothing<BR>%&#062;

  2. #2
    Bob Newsome Guest

    Default RE: sending multiple formfields with cdonts

    I don&#039;t believe you can define more than one field in Request.Form. That is why you are getting nothing.<BR><BR>Try:<BR><BR>Dim BodyText<BR><BR>BodyText = Request.Form("frst_txtfield") & Request.Form("scnd_txtfield") & . . .<BR><BR> or<BR><BR>BodyText = Request.Form("frst_txtfield")<BR>BodyText = Body & Request.Form("scnd_txtfield")<BR>. . .<BR><BR> then<BR><BR>objNewMail.Body = BodyText

Posting Permissions

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