S
simchajoy2000
Hi,
This question will probably be too simplistic for all of you, but I am
trying to teach myself asp and I am having all sorts of problems. I
have a simple html form which calls process.asp on submit:
<html>
<head></head>
<body>
<form action="process.asp" method=Post>
<table cellpadding="0" cellspacing="5" align=center>
<tr>
<td width="100"><font color="#1B157F">Name:</font></font></td>
<td><input type="text" name="txtName" size="55"></td>
</tr>
</table>
<input type="submit" name="Submit" value="Submit Now">
</form>
</body>
</html>
I want my process.asp page to display the name the user entered and
then to send an email containing the information. Here is what I have
so far for the process.asp page:
<html>
<head></head>
<body>
<%
Dim strEmail
Dim strName
strName = Request.Form("txtName")
Response.Write strName
Set MyCDONTSMail = CreateObject("CDONTS.NewMail")
MyCDONTSMail.From = "(e-mail address removed)"
MyCDONTSMail.To = "(e-mail address removed)"
MyCDONTSMail.Subject = "Get-A-Quote Request from " & strName
MyCDONTSMail.Body = MyBody
MyCDONTSMail.Send
Set MyCDONTSMail = Nothing
%>
</body>
</html>
I am not trying to get this to run on a webserver at this point. I am
just trying to get it run in a regular folder on my computer. I
thought that might be the reason why I wasn't receiving any email but
then the Response.Write doesn't work either. When I don't add the html
tags I get a message that asks if I want to save or open the
process.asp page instead of just running it.
A little help? I'm obviously missing something . . . any advice would
be greatly appreciated!
Thank you!
Joy
This question will probably be too simplistic for all of you, but I am
trying to teach myself asp and I am having all sorts of problems. I
have a simple html form which calls process.asp on submit:
<html>
<head></head>
<body>
<form action="process.asp" method=Post>
<table cellpadding="0" cellspacing="5" align=center>
<tr>
<td width="100"><font color="#1B157F">Name:</font></font></td>
<td><input type="text" name="txtName" size="55"></td>
</tr>
</table>
<input type="submit" name="Submit" value="Submit Now">
</form>
</body>
</html>
I want my process.asp page to display the name the user entered and
then to send an email containing the information. Here is what I have
so far for the process.asp page:
<html>
<head></head>
<body>
<%
Dim strEmail
Dim strName
strName = Request.Form("txtName")
Response.Write strName
Set MyCDONTSMail = CreateObject("CDONTS.NewMail")
MyCDONTSMail.From = "(e-mail address removed)"
MyCDONTSMail.To = "(e-mail address removed)"
MyCDONTSMail.Subject = "Get-A-Quote Request from " & strName
MyCDONTSMail.Body = MyBody
MyCDONTSMail.Send
Set MyCDONTSMail = Nothing
%>
</body>
</html>
I am not trying to get this to run on a webserver at this point. I am
just trying to get it run in a regular folder on my computer. I
thought that might be the reason why I wasn't receiving any email but
then the Response.Write doesn't work either. When I don't add the html
tags I get a message that asks if I want to save or open the
process.asp page instead of just running it.
A little help? I'm obviously missing something . . . any advice would
be greatly appreciated!
Thank you!
Joy