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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

help with online form

Status
Not open for further replies.

javaneed

MIS
Mar 13, 2007
1
GB
I have this code below for an online form on a website. The purpose of the form is to get details like, name, phone, message, etc from visitors.
However, when messages are posted and the email is sent to me the content of the messages do not appear.
Am I missing anything??
The code is:


<% @language=”javascript” %>

<%

var name = Request(“name”)+ ””;
var phone = Request(“phone”) + ””;
var email = Request (“email”) + ””;
var msg= Request (“message”) + ””;
var importance = “1”;
var from = “my email address”;
var to = “my email address”+ ””;
var subject = “Contact request”;
Var message = “Name: ” + name + ”\r\n” +
“Phone: ” + phone+ ”\r\n” +
“Email: ” + email+”\r\n” +
“Message: ” + msg + “\r\n”;

var email = Server.CreateObject(CDONTS.NewMail”);
email.Send(from, to, subject, message, importance);
Response.Redirect(“index.html”);

%>
 
That code is ASP. You should post your question in that form.

[monkey][snake] <.
 
Var message =
[tt][red]v[/red]ar message =[/tt]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top