Advertisement
2002ASP Internet/ Browsers/ HTML #8561

Generic Email Form Handler using CDONTS

Email any form from your site using CDONTS (IIS's built-in smtp). Just 10 lines of code handles any size form! Email will display message in the form of fieldname: fieldvalue in proper tab order, with line breaks between each name/value pair.

AI

สรุปโดย AI: This codebase represents a historical implementation of the logic described in the metadata. Our preservation engine analyzes the structure to provide context for modern developers.

ซอร์สโค้ด
original-source
<%
for i=1 to request.form.count
  strMessage = strMessage & request.form.key(i) & ": " & request.form.item(i) & vbCrLf
Next
Set objMail = CreateObject("CDONTS.Newmail")
objMail.From = request.form("Email")
objMail.To = "[email protected]"
objMail.Subject = request.form("Subject")
objMail.Body = strMessage
objMail.Send
Set objMail = Nothing
%>
ความคิดเห็นดั้งเดิม (3)
กู้คืนจาก Wayback Machine