| |
|
if(isset($HTTP_POST_VARS[email])){
if(preg_match("/gmail|yahoo|hotmail/",$HTTP_POST_VARS[email])) {
echo "Warning: Sorry! Please provide your company email account!";
}
else if(preg_match("/synopsys|mentor|cadence|magma|extreme-da|apache-da|clkda|atrenta|dorado-da|atoptech|anova-solutions/",$HTTP_POST_VARS[email])) {
echo "Warning: Sorry! Your download request is denied due to conflict of interest!";
}
else {
$filename_1="/var/www/html/products/files/".$HTTP_POST_VARS[f];
$email=$HTTP_POST_VARS[email];
$SUBJECT="You get the file: ".$HTTP_POST_VARS[f]." from Incentia!";
$BODY_TEXT="Thank you for download the file: ".$HTTP_POST_VARS[f]." from Incentia!";
$cmd="echo '$BODY_TEXT' | mutt -s '$SUBJECT' -a '$filename_1' -F '/var/www/html/products/.muttrc' '$email'";
exec($cmd);
$to = "registrationall@incentia.com";
$subject2= "Incentia Download Customer's Info!";
$message= "Company Email: ".$HTTP_POST_VARS[email]."\r\n".
"Name: ".$HTTP_POST_VARS[name]."\r\n".
"Company: ".$HTTP_POST_VARS[company]."\r\n".
"Phone: ".$HTTP_POST_VARS[phone]."\r\n\r\n".
$headers= "From: Incentia MIS "."\r\n" .
"Reply-To: Incentia MIS "."\r\n".
"X-Mailer: PHP/".phpversion();
mail($to, $subject2, $message, $headers);
echo "The file : ".$HTTP_POST_VARS[f]." is sent with the mail for you!";
}
}
?>
|
| |