if( !eregi( "ventureinformationsystem.com", $_SERVER[ 'HTTP_REFERER' ] ) )
{
print "Please use the form.";
exit();
}
/* PHP Form Updated 2-15-2006 by Nathan
Created to prevent un-authorized mailheader injection attempts, validates mailheaders.
*/
$name =$_GET['name'];
$company =$_GET['company'];
$phone=$_GET['phone'];
$address =$_GET['address'];
$city=$_GET['city'];
$state =$_GET['state'];
$zip =$_GET['zip'];
$email=$_GET['email'];
$url =$_GET['url'];
$send =$_GET['send'];
//$send2 =$_GET['send2'];
$comments =$_GET['comments'];
if (!$email)
{
echo 'Please return to the form, and enter a valid email address.';
exit();
}
/* Else, process the form */
$page="
Dear $name\n
Company: $age\n
Address: $address\n
City: $city\n
State: $state\n
Zip Code: $zip\n
URL: $url\n
Phone: $phone\n
Email Address: $email\n
I would like you to recieve: $send $send2
How did you you hear about the program? $comments
";
/* Mail syntax is as follows: mail($to, $topic, $message, $mailheaders) */
/* Validates that there are no returns, or newlines in the email or message variables */
if (eregi( "\n|\r",$email))
{
mail ( "abuse@oxclove.com","Intrusion Detected!","From: abuse@oxclove.com\r\n","Intrusion detected, someone tried to use: $email");
exit();
}
else
{
$rec="tpeck@csig-ow.com";
//$rec="mike@oxclove.com";
//$rec2="$email";
$topic="Visco Demo Request Form";
//$topic2="Visco Demo Links";
//$mail="From: $email\n\n";
$mailheaders.= "From: $rn <$email>\r\n";
//$mailheaders. = "From: $email\r\n";
$mailheaders.= "MIME-Version: 1.0\r\n";
//$mail="From: $email\n\n";
//$mailheaders2.= "From: $rn <$rec>\r\n";
//$mailheaders. = "From: $email\r\n";
//$mailheaders2.= "MIME-Version: 1.0\r\n";
//$page2="
//Thank for your demo request. Please go here http://yahoo.com
//";
mail($rec,$topic,$page,$mailheaders);
//mail($rec2,$topic2,$page2,$mailheaders2);
echo "
";
}
?>