amy2go
07-09-2002, 11:22 PM
The following is a test page that I'm trying to get to work - figure if I can get this to work, then I can apply it to the real stuff. This may be copied, saved, and run as is:
<html>
<head>
<title>Email Test</title>
<script language="javascript" type="text/javascript">
function fnSubmit(){
var email = "mailto:";
email += frmEmail.RecipientAddress.value;
frmEmail.action = email;
return true;
}
</script>
</head>
<body bgcolor="#FFFFFF">
<form onSubmit="return fnSubmit()" action="" method="post" ENCTYPE="text/plain" name="frmEmail">
<input name="RecipientAddress" size=50 type="text">
<b>To: (Enter E-Mail Address)</b><br>
<p>
<b>Write a message to recipient:</b><br>
<p>
<textarea name="NoteToRecipient" rows=10 cols=50></textarea><p>
<input type=submit value="SEND">
<input type=reset value="CLEAR">
</form>
</body>
</html>
This is the resulting email with subject line "Form posted from Microsoft Internet Explorer":
RecipientAddress=amy2go@attbi.com
NoteToRecipient=This is a test.
If I change the ENCTYPE to "text/html", I get the same results. What I want is the actual page to be emailed, not just the values from the form, and it would be nice to change the subject line. Problem is, I'm not on a Unix server; I'm on a Windows server, and there's just not a lot of samples for this.
-Amy
<html>
<head>
<title>Email Test</title>
<script language="javascript" type="text/javascript">
function fnSubmit(){
var email = "mailto:";
email += frmEmail.RecipientAddress.value;
frmEmail.action = email;
return true;
}
</script>
</head>
<body bgcolor="#FFFFFF">
<form onSubmit="return fnSubmit()" action="" method="post" ENCTYPE="text/plain" name="frmEmail">
<input name="RecipientAddress" size=50 type="text">
<b>To: (Enter E-Mail Address)</b><br>
<p>
<b>Write a message to recipient:</b><br>
<p>
<textarea name="NoteToRecipient" rows=10 cols=50></textarea><p>
<input type=submit value="SEND">
<input type=reset value="CLEAR">
</form>
</body>
</html>
This is the resulting email with subject line "Form posted from Microsoft Internet Explorer":
RecipientAddress=amy2go@attbi.com
NoteToRecipient=This is a test.
If I change the ENCTYPE to "text/html", I get the same results. What I want is the actual page to be emailed, not just the values from the form, and it would be nice to change the subject line. Problem is, I'm not on a Unix server; I'm on a Windows server, and there's just not a lot of samples for this.
-Amy