Greeeeeetings!
I recently upgraded my site to php5 and noticed a script I have is no longer functioning properly. It's called Snowmail and I cannot find any website for it now with any updated info.
The purpose is for a user to input their name and number into a .SWF form and 3 actions happen:
~ The data is put into my database
~ an email is sent to me with the inputted data
~ the .SWF displays a message with the person's name indicating the data was received.
Well since the php5 switch, the database still gets the data but the email to me is blank as is the person's name on the callback. "Thanks, ! Your submission has been sent!!!"
I was hoping someone could let me know how to make this php5-ready.
Since the connection to the DB works, I'm not including that code.
Asterisks are being used to replace the actual content I have in there.
<?php
include('connect.php');
$ToEmail = "***@****";
##$ToName = "***";
$ToSubject = "***";
$EmailBody = "PHONE NUMBER COLLECTED: $phone\n\nSENDER'S NAME: $name\n";
$EmailFooter = "\n----------------------------------\nThis message was sent through ***.com from $REMOTE_ADDR\n";
$EmailPresetText = "\nA submission has come through. \nPlease contact this person using the information provided below.\n";
$Message = $EmailPresetText.$EmailBody.$EmailFooter;
mail($ToName." <".$ToEmail.">",$ToSubject, $Message, "From: ".$name." <".$email.">");
Print "_root.Mail.status=Thanks, ".$name."! Your submission has been sent!!!";
?>
<?php
$name = $_POST['name'];
$phone = $_POST['phone'];
$connection = new connection;
$query = "INSERT INTO phones (name,phone) VALUES ('$name','$phone')";
$connection->queryString($query);
?>