Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

form submission page

Status
Not open for further replies.

chaddu1256

IS-IT--Management
Jan 13, 2003
28
US
We recieved a website from our web hoster so we could host the website locally at our facility. On the webpage there are two form submission pages. There is a mailaction.asp script file that was in the root directory of the webpage which I know is used to actually send the forms to an email address when you click the submit button. I will post the script here in a second but I just wanted to know what we needed to do on our web server here to actually get this submission page working again. Any info would be great.

<%@ LANGUAGE = VBScript %>
<html>
<head>
<title>Contact EMail</title>
<%

if Request.Form(&quot;Name&quot;).Count Then

szEmail_to = &quot;info@billeradvantage.com&quot;
szTo_name = &quot;Biller Advantage&quot;

szEmail_from = Request.Form(&quot;E-mail&quot;)
szFrom_name = Request.Form(&quot;Name&quot;)
szSubject = &quot;BillerAdvantage Partnership Request&quot;
szMessage = &quot;&quot;

szMessage = &quot;BillerAdvantage Partnership Request Form:&quot; & chr(10) & chr(10) &_
&quot;Name: &quot; & Request.Form(&quot;Name&quot;) & chr(10) &_
&quot;Last Name: &quot; & Request.Form(&quot;Lastname&quot;) & chr(10) &_
&quot;Company Name: &quot; & Request.Form(&quot;Company&quot;) & chr(10) &_
&quot;Address: &quot; & Request.Form(&quot;Address1&quot;) & chr(10) &_
&quot;Address2: &quot; & Request.Form(&quot;Address2&quot;) & chr(10) &_
&quot;City: &quot; & Request.Form(&quot;City&quot;) & chr(10) &_
&quot;State: &quot; & Request.Form(&quot;State&quot;) & chr(10) &_
&quot;Zip: &quot; & Request.Form(&quot;Zip&quot;) & chr(10) &_
&quot;Phone: &quot; & Request.Form(&quot;Phone&quot;) & chr(10) &_
&quot;Fax: &quot; & Request.Form(&quot;Fax&quot;) & chr(10) &_
&quot;Email: &quot; & Request.Form(&quot;Email&quot;) & chr(10)


Set Mail = Server.CreateObject(&quot;Persits.MailSender&quot;)
Mail.Host = &quot;localhost&quot; ' Specify a valid SMTP server
Mail.From = szEmail_from ' Specify sender's address
Mail.FromName = szFrom_name ' Specify sender's name

Mail.AddAddress szEmail_to, szTo_name
Mail.AddReplyTo szEmail_from

Mail.Subject = szSubject
Mail.Body = szMessage
On Error Resume Next
Mail.SendToQueue

End If
%>
<script language=javascript>
location.replace(&quot;index.htm&quot;);
</script>
 
Make sure your SMTP service is up and running. <Control Panel><Administrative Tools><Computer Management><Services and Applications><Internet Information Services><Default SMTP Virtual Server>

I don't see where you're including the file that contains the email component script.
 
What do you mean by the email component script? Sorry, but this is my first time having to set something up like this.
 
Well, you're not using CDONTS because if you were the instantiation line would read: Set Mail = Server.CreateObject(&quot;CDONTS.NewMail&quot;) instead of Set Mail = Server.CreateObject(&quot;Persits.MailSender&quot;). This leads me to believe that you've got a 3rd party email gizmo (script,component). If it's a script you'll need to <!--#Include file=&quot;myEmailScript&quot;--> so the page that sends the mail can get to it. If it's some kind of component you'll probably have to register it on your server.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top