Jump to content

receiving dodgy emails


amatuer

Recommended Posts

Hi all,

I'm using the feedback code below in which i get a whole heap of emails which dont make sense, sometimes their blank, mostly others have text in it. Somedays I might recieve a couple of hundred a day. Below if the php code.

<?

$SendTo = "emailaddress";
$ThanksURL = "thankyou.htm"; //confirmation page
$SubjectLine = "Oil Change Express Website Feedback";
$name = $_POST['name'] ;
$email = $_POST['email'] ;
$telephone = $_POST['telephone'] ;
$enquiry = $_POST['enquiry'] ;
$http_referrer = getenv( "HTTP_REFERER" );
$Divider = "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~";

// Build Message Body from Web Form Input
$MsgBody = @gethostbyaddr($_SERVER["REMOTE_ADDR"]) . "\n$Divider\n";

$MsgBody =
"This message was sent from:\n" .
"$http_referrer\n" .
"--------------------------------------------------\n\n" .
"Name: $name\n" .
"Email: $email\n" .
"Telephone Number: $telephone\n" .
"------------------------- ENQUIRY -------------------------\n\n" .
$enquiry .
"\n\n------------------------------------------------------------\n" ;

mail($SendTo, $SubjectLine, $MsgBody, "From: \"$name\"emailaddress\r\nReply-To: \"$name\" <$email>\r\nX-Mailer: chfeedback.php 2.04" );
header("Location: $ThanksURL");

?>

-------------------------------------------------------------------------------------

These are some of the emails I receive.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.