Forum Moderators: coopster
<?php
If post then {
?>
form fields
<form action="<?php $_SERVER['PHP_SELF'] ;?>" method='post'>
<input fields here>
type='submit' name='Submit' value='Submit'>
</form>
<?php
}
else {
$con = mysql_connect("mysql","databasename","password");
$sql="INSERT INTO etc.
if (!mysql_query($sql,$con))
{die('Error: ' . mysql_error());}
This is where I get stuck. Where to add the email fields. So that some of the above form fields will send to the email as well. I tried......
else {
$mailto = etc. and so on here.
echo "form fields sent";}}
?>
But it says unexpected Telse on the last else. Thanks.