من پي اچ پي كار مي كنم. ولي اينو امتحان كن. احتمال 99.9999999 % كار كنه !!! :happy:
اينو كپي كن. چون اينجا فارسيه برعكس ميبيني. وقتي پيست اش كني درست ميشه.
موفق باشيد.
<!--METADATA TYPE="typelib" UUID="CD000000-8B95-11D1-82DB-00C04FB1625D" NAME="CDO for Windows 2000 Type Library" -->
<!--METADATA TYPE="typelib" UUID="00000205-0000-0010-8000-00AA006D2EA4" NAME="ADODB Type Library" -->
<%
Dim sRecipient
Dim sFrom
Dim sSMTPserver
Dim sBody
Dim x
Dim sRedirect
'************************************************************************************************
' only modify this section
sRecipient = "
[email protected]" 'you email address the form will be emailed to
sFrom = "
[email protected]" 'your form address here
sSubject = "E-mail subject" 'a simple subject line
sRedirect = "thanks.htm" 'the page to redirect to once the email is sent
sSMTPServer = "mta174.mail.re2.yahoo.com" 'your SMTP server *may* work as 127.0.0.1 otherwise contact your host
' you shouldnt need to modify anything below this line
'************************************************************************************************
' add all form items to the body of the email
' in a name = <form entry> format
For x = 1 TO (Request.Form.Count())
If Not Request.Form(x) = "" Then
sBody = sBody & vbCrLf & Request.Form.Key(x) & " = " & Trim(Request.Form(x)) & vbCrLf
End If
Next
'*****************************************
' set up and send the email
Dim iMsg
Dim Flds
Dim iConf
Set iMsg = CreateObject("CDO.Message")
Set iConf = CreateObject("CDO.Configuration")
Set Flds = iConf.Fields
Flds(cdoSendUsingMethod) = cdoSendUsingPort
Flds(cdoSMTPServer) = sSMTPserver
Flds(cdoSMTPServerPort) = 25
Flds(cdoSMTPAuthenticate) = cdoAnonymous
Flds.Update
With iMsg
Set .Configuration = iConf
.To = sRecipient
.From = sFrom
.Sender = sFrom
.Subject = sSubject
.TextBody = "" & sBody & ""
.Send
End With
Set iMsg = Nothing
Set iConf = Nothing
Set Flds = Nothing
response.redirect sRedirect
%>