Please help me fix this error - THANKS!!!!

Website: www.trumpcardmarketing.com

PHP Form Mail Error is as followed:
Parse error: parse error, unexpected '@' in /home/content/r/m/c/rmcrorie/html/trump/PHPformmailer.php on line 21

PHP line in question is as followed:
@mail($pfw_email_to, $pfw_subject ,$pfw_message ,$pfw_header ) ;

PHP Code is as followed:

<?php

// Receiving variables
@$pfw_ip= $_SERVER['REMOTE_ADDR'];
@$NAME = addslashes($_POST['NAME']);
@$EMAIL = addslashes($_POST['EMAIL']);
@$PHONE = addslashes($_POST['PHONE']);
@$MESSAGE = addslashes($_POST['MESSAGE']);

// Validation
//Sending Email to form owner
$pfw_header = "From: $EMAIL\n"
  . "Reply-To: $EMAIL\n";
$pfw_subject = "Integrated Communications";
$pfw_email_to = "ryan@trumpcardmarketing.com";
$pfw_message = "Visitor's IP: $pfw_ip\n"
. "NAME: $NAME\n"
. "EMAIL: $EMAIL\n"
. "PHONE: $PHONE\n"
. "MESSAGE: $MESSAGE\n"
@mail($pfw_email_to, $pfw_subject ,$pfw_message ,$pfw_header ) ;

 echo("<p align='center'><font face='Eras Bold ITC' size='3' color='#2B2B2B'>Thank you for your message!<br><br>You will receive a response within 48-hours.<br><br>Take care!</font></p>");
?>

Recommended Answers

All 2 Replies

put a ";" at the end of line 20

Works perfectly now!!! Thanks Robb!!!!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.