Hi - Not sure if this is exactly the right forum to enter this is - but need to start somewhere as I don't know where it's not working.
I have a contact form on a flash website, when the submit button is pressed, another window opens to say the mail has been sent - when it hasn't (Ihave changed this to read there was a problem). I can't see anything in the logfiles to say what hasn't worked - but it's driving me crazy. The file called upon is contact.php which is why I'm here;
[code=php]
<?
Error_Reporting (E_ALL & ~E_NOTICE);
while ($request = current($_REQUE ST)) {
if (key($_REQUEST) !='recipient') {
$pre_array=spli t ("&777&", $request);
$post_vars[key($_REQUEST)][0]=$pre_array[0];
$post_vars[key($_REQUEST)][1]=$pre_array[1];
}
next($_REQUEST) ;
}
reset($post_var s);
$sendTo ="Web@email.co. uk" ;
$subject="From ".$post_var s['your_name'][0] ;
$headers="From: ".$post_var s['your_email'][0] ."\n";
$headers.='Cont ent-type: text/html; charset=iso-8859-1';
$message='';
while ($mess = current($post_v ars)) {
if ((key($post_var s)!="i") && (key($post_vars )!="your_email" ) && (key($post_vars )!="your_name") ) {
$message.="<str ong>".$mess[1]."</strong> &n bsp; ".$me ss[0]."<br>";
}
next($post_vars );
}
mail($sendTo, $subject, $message. $headers);
echo ("There was a problem sending the email - sorry for the inconvenience") ;
?>
[/code]
Can anyone help? Do you need anymore information?
Thanks
TB
I have a contact form on a flash website, when the submit button is pressed, another window opens to say the mail has been sent - when it hasn't (Ihave changed this to read there was a problem). I can't see anything in the logfiles to say what hasn't worked - but it's driving me crazy. The file called upon is contact.php which is why I'm here;
[code=php]
<?
Error_Reporting (E_ALL & ~E_NOTICE);
while ($request = current($_REQUE ST)) {
if (key($_REQUEST) !='recipient') {
$pre_array=spli t ("&777&", $request);
$post_vars[key($_REQUEST)][0]=$pre_array[0];
$post_vars[key($_REQUEST)][1]=$pre_array[1];
}
next($_REQUEST) ;
}
reset($post_var s);
$sendTo ="Web@email.co. uk" ;
$subject="From ".$post_var s['your_name'][0] ;
$headers="From: ".$post_var s['your_email'][0] ."\n";
$headers.='Cont ent-type: text/html; charset=iso-8859-1';
$message='';
while ($mess = current($post_v ars)) {
if ((key($post_var s)!="i") && (key($post_vars )!="your_email" ) && (key($post_vars )!="your_name") ) {
$message.="<str ong>".$mess[1]."</strong> &n bsp; ".$me ss[0]."<br>";
}
next($post_vars );
}
mail($sendTo, $subject, $message. $headers);
echo ("There was a problem sending the email - sorry for the inconvenience") ;
?>
[/code]
Code:
<script> resizeTo(450, 300); </script>
Thanks
TB
Comment