home *** CD-ROM | disk | FTP | other *** search
/ Australian Personal Computer 1999 April / APC443.iso / features / grpware / coldfus / coldfusi.exe / data1.cab / Documentation / snippets / cfmail.cfm < prev    next >
Encoding:
Text File  |  1998-10-08  |  1.6 KB  |  48 lines

  1. <!--- This view-only example shows the use of CFMAIL --->
  2. <HTML>
  3. <HEAD>
  4. <TITLE>CFMAIL Example</TITLE>
  5. </HEAD>
  6.  
  7. <BODY bgcolor=silver>
  8. <H3>CFMAIL Example</H3>
  9. <P>This view-only example shows the use of CFMAIL.  If your CFAS mail 
  10. settings are configured successfully and the comments are removed,
  11. you will be able to use this code to send simple email.
  12. <!---  <CFIF IsDefined("form.mailto")>
  13.     <CFIF form.mailto is not "" AND form.mailfrom is not "" AND form.Subject is not "">
  14.     <CFMAIL TO="#form.mailto#"
  15.             FROM="#form.mailFrom#"
  16.             SUBJECT="#form.subject#">
  17.             This message was sent by an
  18.             automatic mailer built with CFMAIL:
  19.             ====================================================
  20.             #form.body#
  21.     </CFMAIL>    
  22.     <H3>Thank you</H3>
  23.     <P>Thank you, <CFOUTPUT>#mailfrom#: your message, #subject#, has
  24.     been sent to #mailto#</CFOUTPUT>.
  25.     </CFIF>    
  26. </CFIF>
  27. <P>
  28. <FORM ACTION="cfmail.cfm" METHOD="POST">
  29. <PRE>
  30. TO:         <INPUT TYPE="Text" NAME="MailTo">
  31. FROM:        <INPUT TYPE="Text" NAME="MailFrom">
  32. SUBJECT:    <INPUT TYPE="Text" NAME="Subject">
  33. <hr>
  34. MESSAGE BODY:
  35. <TEXTAREA NAME="Body" COLS="40" ROWS="5" WRAP="VIRTUAL"></TEXTAREA>
  36. </PRE>
  37. <!--- establish required fields --->
  38. <INPUT TYPE="Hidden" NAME="MailTo_required" VALUE="You must enter a recipient for this message">
  39. <INPUT TYPE="Hidden" NAME="MailFrom_required" VALUE="You must enter a sender for this message">
  40. <INPUT TYPE="Hidden" NAME="Subject_required" VALUE="You must enter a subject for this message">
  41. <INPUT TYPE="Hidden" NAME="Body_required" VALUE="You must enter some text for this message">
  42.  
  43. <P><INPUT TYPE="Submit" NAME="">
  44. </FORM>  --->
  45.  
  46. </BODY>
  47. </HTML>       
  48.