[Solved]Confused??
Posted: Sun Feb 18, 2007 1:27 pm
Ok, I cant understand why this isnt doing anything, maybe some one can point me in the right direction to help fix this.
When it tries to send it doesnt give me a confirmation and/or a error like it should..I'm still a lil green at php and maybe I just another set of eyes to look at it.
Thanks in Advance,
Bryan "gimpy"
When it tries to send it doesnt give me a confirmation and/or a error like it should..I'm still a lil green at php and maybe I just another set of eyes to look at it.
Code: Select all
///////////////////////////
//Begin Configuration
///////////////////////////
// Your email
$to = "bw.gimpy@gmail.com" . ", " ;
// Email Subject
$subject = "Game Directory filing" . "TX3Guilds.com";
// Server name, to display in the headers
$server_name = "TX3Guilds.com";
///////////////////////////
//End Configuration
///////////////////////////
if (!empty($_POST['send']) || !empty($_GET['send']))
{
$action = (!empty($_POST['send'])) ? $_POST['send'] : $_GET['send'];
}
else
{
$action = '';
}
$build_message = false;
if($action != "")
{
$build_message = true;
$message = $_POST['games'];
$name = $_POST['name'];
$email = $_POST['email'];
$website = $_POST['website'];
//$time = time();
$date = date("F j, Y", time());
$headers = "MIME-Version: 1.0\r\n";
$headers .= "Content-type: text/plain; charset=UTF-8\r\n";
$headers .= "From: $email\r\n";
$headers .= "X-mailer: " . $server_name . " Server\r\n";
}
if($build_message)
{
/* message */
$message = "
Sender Name: $name\n
Sender E-Mail: $email\n
Date Sent: $date\n
Message:\n----------------------------------------\n$message \n$website\n";
if(mail($to, $subject, $message, $headers))
{
$result = "<b>Thank you</b>.<br />I will get back to you very soon.<br />";
}
else
{
$result = "Sorry: An error occured, please try again later.";
}
}
// Output a result Message
print $result;Bryan "gimpy"