LogicalDohnuts
Dec 20th, 2007, 04:00 PM
Hey guys, I'm making a email script for my company and currently I've got it all rigged up and it should be working, but my email just won't work? What I mean by this is that, even thou I make it use Mail(mysettings etc) the email never comes to me. Could one of you check my script? Thanks.
<?php
// You may edit these to your likings.
$email = "randomfirework@gmail.com"; // Contact email, for visitors
$emailredirectpage = "emailsuccess.php"; // The page they will be re-directed too.
$emailmaxmessage = "500"; // Maximum characters for their message.
// Connected to main form, and grab necessary data.
$emailtitle = $_POST['title'];
$emailmsg = $_POST['message'];
// This is protection against any potential attacks.
$emailtitle = trim($emailtitle);
$emailtitle = preg_replace("/>/","]",$emailtitle);
$emailtitle = preg_replace("/</","[",$emailtitle);
// Finally email the client all the information.
//mail($email,$emailtitle,$emailmsg);
$headers = str_replace(”\r\n”,”\n”,$headers);
@mail ($email, $emailtitle, $emailmsg, $headers);
// End of script.
?>
:thumb:
<?php
// You may edit these to your likings.
$email = "randomfirework@gmail.com"; // Contact email, for visitors
$emailredirectpage = "emailsuccess.php"; // The page they will be re-directed too.
$emailmaxmessage = "500"; // Maximum characters for their message.
// Connected to main form, and grab necessary data.
$emailtitle = $_POST['title'];
$emailmsg = $_POST['message'];
// This is protection against any potential attacks.
$emailtitle = trim($emailtitle);
$emailtitle = preg_replace("/>/","]",$emailtitle);
$emailtitle = preg_replace("/</","[",$emailtitle);
// Finally email the client all the information.
//mail($email,$emailtitle,$emailmsg);
$headers = str_replace(”\r\n”,”\n”,$headers);
@mail ($email, $emailtitle, $emailmsg, $headers);
// End of script.
?>
:thumb: