Hello all,
I am writing a php script that sends an email via a web form. I am trying to suppress the information that is null so it will not be included in the email. The email send and recieves fine, but the information is not being included in the email. It is acting as though everything is null. But here is the crazy part. If I am using a Mac(regardless of browser), the form will work fine and the information is supplied in the email.Yet on any PC(regardless of browser) the email returns nothing.
Here is the code. Any help would be greatly appreciated!!
<?
if (!is_array($HTTP_POST_VARS)) //validates array
return;
reset($HTTP_POST_VARS);
while
(list($key, $val) = each($HTTP_POST_VARS)) { //traverses the array
if ($val!=""
{
$GLOBALS[$key] = $val;
$val=stripslashes($val);
echo "<b>$key</b> = $val<br>";
$Message .= "$key = $val\n";
}}
if ($Header) {
$Message = $Header."\n\n".$Message;
}
if ($Footer) {
$Message .= "\n\n".$Footer;
}
mail( "$MailToAddress", "$MailSubject", "$Message", "From: $MailFromAddress"
;
?>
I am writing a php script that sends an email via a web form. I am trying to suppress the information that is null so it will not be included in the email. The email send and recieves fine, but the information is not being included in the email. It is acting as though everything is null. But here is the crazy part. If I am using a Mac(regardless of browser), the form will work fine and the information is supplied in the email.Yet on any PC(regardless of browser) the email returns nothing.
Here is the code. Any help would be greatly appreciated!!
<?
if (!is_array($HTTP_POST_VARS)) //validates array
return;
reset($HTTP_POST_VARS);
while
(list($key, $val) = each($HTTP_POST_VARS)) { //traverses the array
if ($val!=""
$GLOBALS[$key] = $val;
$val=stripslashes($val);
echo "<b>$key</b> = $val<br>";
$Message .= "$key = $val\n";
}}
if ($Header) {
$Message = $Header."\n\n".$Message;
}
if ($Footer) {
$Message .= "\n\n".$Footer;
}
mail( "$MailToAddress", "$MailSubject", "$Message", "From: $MailFromAddress"
?>