Tayfun
08-11-2009, 03:59 PM
Hi
I have a fill-out form on a html page that runs by a php script.
On the html page I have 2 checkboxes under the fill-out form;
1. send a copy of this message to my address
2. Newsletter subscription
When the first one is checked I would need a message to be sent to the sender with a subject: "Copy of your sent contact message"
Is it possible to ad something into this script.
Would appreciate your help, thanks!
Code of the php script
<?
$subject="from ".$_GET['Name'];
$headers= "From: ".$_GET['e-mail']."\n";
$headers.='Content-type: text/html; charset=iso-8859-1';
mail("my.mail@email.com", $subject ="Contact message", "
<html>
<head>
<title>Contact message</title>
</head>
<body>
<br>
".$_GET['Name']."
".$_GET['Surrname']."
<br>
".$_GET['Address']."
<br>
".$_GET['Post.Nr']."
".$_GET['City']."
<br>
".$_GET['Telephone']."
<br>
".$_GET['e-mail']."
<br>
<br>
".$_GET['Newsletter_confirmation']."
<br>
<br>
".$_GET['Message']."
</body>
</html>" , $headers);
?>
<script language="JavaScript" type="text/JavaScript">
<!--
window.location.href = "http://www.feltne.com/oddano_s.htm";
//-->
</script>
I have a fill-out form on a html page that runs by a php script.
On the html page I have 2 checkboxes under the fill-out form;
1. send a copy of this message to my address
2. Newsletter subscription
When the first one is checked I would need a message to be sent to the sender with a subject: "Copy of your sent contact message"
Is it possible to ad something into this script.
Would appreciate your help, thanks!
Code of the php script
<?
$subject="from ".$_GET['Name'];
$headers= "From: ".$_GET['e-mail']."\n";
$headers.='Content-type: text/html; charset=iso-8859-1';
mail("my.mail@email.com", $subject ="Contact message", "
<html>
<head>
<title>Contact message</title>
</head>
<body>
<br>
".$_GET['Name']."
".$_GET['Surrname']."
<br>
".$_GET['Address']."
<br>
".$_GET['Post.Nr']."
".$_GET['City']."
<br>
".$_GET['Telephone']."
<br>
".$_GET['e-mail']."
<br>
<br>
".$_GET['Newsletter_confirmation']."
<br>
<br>
".$_GET['Message']."
</body>
</html>" , $headers);
?>
<script language="JavaScript" type="text/JavaScript">
<!--
window.location.href = "http://www.feltne.com/oddano_s.htm";
//-->
</script>