Jump to content

Parse the error!


eaglelegend

Recommended Posts

Thats what its like you think you have solved one thing then another parse error pops up, heres my problem below; (I hope its enough)

 

Parse error: syntax error, unexpected ';' in /misc/39/000/171/334/2/user/web/eaglelegend.com/mail2.php on line 61

 

	if($a == 'sendmsg' && $_POST['type'] == 1){
	$headers  = "MIME-Version: 1.0\r\n";
	$headers .= "Content-type: text/plain; charset=iso-8859-1\r\n";
	$headers .= "To: ".trim($_POST['to'])."\r\n";
	$headers .= "From: ".trim($_POST['from'])."\r\n";
	$headers .= "Reply-To: ".trim($_POST['from'])."\r\n";
      @mail(trim($_POST['to']), trim($_POST['subject']), $_POST['message'], $headers);
	echo("Mail sent to ".trim($_POST['to']); /*line 61*/)
}

Link to comment
https://forums.phpfreaks.com/topic/100762-parse-the-error/
Share on other sites

<?php

if($a == 'sendmsg' && $_POST['type'] == 1){

$headers  = "MIME-Version: 1.0\r\n";

$headers .= "Content-type: text/plain; charset=iso-8859-1\r\n";

$headers .= "To: ".trim($_POST['to'])."\r\n";

$headers .= "From: ".trim($_POST['from'])."\r\n";

$headers .= "Reply-To: ".trim($_POST['from'])."\r\n";

      @mail(trim($_POST['to']), trim($_POST['subject']), $_POST['message'], $headers);

echo("Mail sent to ".trim($_POST['to']) );

}

?>

Link to comment
https://forums.phpfreaks.com/topic/100762-parse-the-error/#findComment-515390
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.