How do I alter the follow asp code so the from field produces the a friendly
address
"Name <so*******@chan geme.com>"
Code is presently used.
<%
If Request.Form("b tnSend").Count 0 Then
Set objMessage = CreateObject("C DO.Message")
objMessage.Subj ect = Request.Form("s ubject")
objMessage.Send er = Request.Form("F rom")
objMessage.To = Request.Form("T o")
objMessage.Text Body = Request.Form("m essage")
objMessage.Conf iguration.Field s.Item _
("http://schemas.microso ft.com/cdo/configuration/sendusing") = 2
objMessage.Conf iguration.Field s.Item _
("http://schemas.microso ft.com/cdo/configuration/smtpserver") =
"mailserver "
objMessage.Conf iguration.Field s.Item _
("http://schemas.microso ft.com/cdo/configuration/smtpserverport" ) = 25
objMessage.Conf iguration.Field s.Update
objMessage.Send
Response.Redire ct("../thanks.htm")
End If
%>
<form action="contact .asp" method="post" name="sendEmail " class="content" >
<input type="hidden" name="subject" value="Enquiry from Web Site">
<input type="hidden" name="to"
value="en****** *@chaucer.sheff ield.sch.uk"/>
<table align="center" cellpadding="5" bordercolor="#0 00000"
class="content" >
<tr>
<td>Your Email Address</td>
<td><input name="From" type="text" class="content" size="53"
/></td>
</tr>
<tr>
<td valign="top"><d iv align="right">Y our Message</div></td>
<td><textarea name="message" cols="50" rows="6"
wrap="VIRTUAL" class="content" ></textarea>
</td>
</tr>
<tr>
<td colspan="2"><di v align="center">
<input name="Send" type="submit" />
</div></td>
</tr>
</table>
<div align="center"> </div>
<div align="center"> </div>
</form>
Thank you any help.
Steve
"privatenews.mi crosoft.com" wrote:
Try,
http://weblogs.asp.net/steveschofiel...ipt_2E00_.aspx
Thanks,
Steve Schofield
Microsoft MVP - IIS
"Steve Audus, Chaucer BEC, Sheffield UK"
<St************ *************** **@discussions. microsoft.comwr ote in message
news:10******** *************** ***********@mic rosoft.com...I have successful setup email forms on our web site using CDO and ASP
scripting,
using this coding
http://www.ilopia.com/Articles/Windo...r2003/CDO.aspx
It is used on this page
http://www.chaucer.sheffield.sch.uk/about/contact.asp
The form works, but when the mail arrives it in the inbox, the senders
name
is not displayed, as it is not included in the form.
Only "From (Email Address)" and "Message" are included.
How do I add a name field, and maybe extra field to be included in the
message.
Thank you for any help.