amirhossin
Member
چطوري مي شه با asp يه فرم ايميل ساخت؟
ممنون
ممنون
<!-- FIRSTPAGE - Called quikmail.asp -->
<HTML>
<HEAD><TITLE>Quik Mail</TITLE></HEAD>
<BODY link=blue alink=blue vlink=blue>
<FORM action="quikmail2.asp">
<H3>Quik Mail</H3>
<TABLE width=75% border=0>
<TR><TD valign=top>To:</TD><TD><INPUT type=text name=theiremail></TD></TR>
<TR><TD valign=top>From:</TD><TD><INPUT type=text name=youremail></TD></TR>
<TR><TD valign=top>Subject:</TD><TD><INPUT type=text name=subject></TD></TR>
<TR><TD valign=top>Message:</TD><TD><TEXTAREA rows=15 cols=60 name=message></TEXTAREA>
</TD></TR>
<TR><TD></TD><TD align=center><INPUT type=submit value="Send Quik Mail" name=submit></TD></TR>
</TABLE>
<HR>
</FORM>
</BODY></HTML>
<!-- SECOND PAGE - quikmail2.asp -->
<%
message=request("message")
theiremail=request("theiremail")
youremail=request("youremail")
subject=request("subject")
message=request("message")
Sub sendmessage(from,towhom,subject,message)
Set Mailer = Server.CreateObject("SMTPsvg.Mailer")
Mailer.RemoteHost = "smtp-server.austin.rr.com"
Mailer.FromAddress = from
Mailer.AddRecipient towhom,towhom
Mailer.Subject = subject
Mailer.BodyText= message
if Not Mailer.SendMail Then
response.write "Mailing Failed... Error is: <BR>"
response.write Mailer.Response
End if
End Sub
sendmessage youremail,theiremail,subject,message
response.redirect "ANYPAGE YOU WANT To GO TO !!!!"
%>