Ok ok, i went back and read what he posted, i noticed theI have taken a jist of the coding and posted here.
while ($mess = current($post_vars)) {
if ((key($post_vars)!="i") && (key($post_vars)!="your email here") && (key($post_vars)!="your name here")) {
$message.="<strong>".$mess[1]."</strong> ".$mess[0]."<br>";
}
next($post_vars);
}
/***************************************************************/
mail($_REQUEST['recipient'], $subject, "
<html>
<head>
<title>Contact letter</title>
</head>
<body>
<br>
".$message."
</body>
</html>" , $headers);
echo ("Your message was successfully sent!");
Now do you see a line like this
/*****************************************/
now that the place which i meant. Now instead of that line
put this statement first.
echo $mess;
Now get the message that is printed on your browser when you execute this script.
Now use this statement and do as i have said for the other statement.
echo current($post_vars);
Get me the message that is being displayed on the screen, so that i can analyse the problem better and come out with a solution.
PHP:
mail($_REQUEST['recipient'], $subject, "
Code:
<?
Error_Reporting(E_ALL & ~E_NOTICE);
while ($request = current($_REQUEST)) {
if (key($_REQUEST)!='recipient') {
$pre_array=split ("&777&", $request);
$post_vars[key($_REQUEST)][0]=$pre_array[0];
$post_vars[key($_REQUEST)][1]=$pre_array[1];
}
next($_REQUEST);
}
reset($post_vars);
$subject="From ".$post_vars['your_name'][0] ;
$headers = "MIME-Version: 1.0\r\n";
$headers.= "Content-Type: text/html;";
$headers.= "Charset=iso-8859-1\r\n";
$headers.= "From: ".$post_vars['your_email'][0];
$message='';
while ($mess = current($post_vars))
{
if ((key($post_vars)!="i") && (key($post_vars)!="your email here") && (key($post_vars)!="your name here"))
{
$message.="<strong>".$mess[1]."</strong> ".$mess[0]."<br>";
}
next($post_vars);
}
mail($_REQUEST['recipient'], $subject, "
<html>
<head>
<title>Contact letter</title>
</head>
<body>
<br>
".$message."
</body>
</html>";
[u][b]mail("shigerumiyamoto1@yahoo.com", $subject, $message, $headers);[/b][/u]
echo ("Your message was successfully sent!");
?>
<script>
resizeTo(300, 300);
</script>
Compare the QWOTED code that sunil posted with my surrect contact.php code... the BOLD and underlined line is not in the code that sunil posted, but it is still present in my contact.php, what should i do with it?
And then, what do i do next? Testing that code, which code, where exactly? please repeat the specific instructions please, I'm really 0% expereince with php or any coding language... :/ again thanks for understanding.
Last edited: