I can't get this mail to work. I've already tried a lot of things. Can you guys help me?
Source below. It does the insertion and all that fine, but it won't put out the e-mail. It never comes to my box 🙁
<?php
//variable contains data necessary to connect to mySQL.
$connect = mysql_pconnect("localhost", "mynameisbingo", "*************") or die("Connect failed");
//variable contains data necessary to select the mySQL database.
$pickme = mysql_select_db("mynameisbingo_com") or die("Couldn't select database.");
if($to){
mysql_query("INSERT INTO tmly VALUES ('$to', '$email', '$uname', '$uemail', '$ecolor', '$hcolor', '$ager', '')")or die("Failed to add values.");
}
$getstuff = mysql_query("SELECT * FROM tmly")or die("Couldn't receive values!");
while ($getstuff2=mysql_fetch_array($getstuff))
{
$uemail=$getstuff2['uemail'];
$email=$getstuff2['email'];
$uname=$getstuff2['uname'];
$to=$getstuff2['to'];
$id=$getstuff2['id'];
}
/*subject*/
$subject = "The Monkey Loves Ya!";
/*message*/
$message="Hello $to,
You have received this e-mail because a secret crush, so to speak, entered your name at THE THE MONKEY LOVES YA ONLINE THINGY. You must visit the address below to find out who it is, but you have to guess who they are. So it's like a fun little game thing. Get it?
We burglurized this idea from another site out there. I don't even remember what it's called. The one they use doesn't work. It just keeps requesting more and more and more and more and more email addresses so it can spam them. Ours works.
Drop in at [url]www.mynameisbingo.com/funwithphp/tmly/viewalizer.php?[/url]$id=id to try and guess who either actually loves or is pretending to love you. You can also visit [url]www.mynameisbingo.com,[/url] the home of the THE THE MONKEY LOVES YOU ONLINE THINGY. It's cool yo.
End.
";
$headers = "MIME-Version: 1.0\r\n";
$headers .= "Content-type: text/html; charset=iso-8859-1\r\n";
$headers .= 'Cc: $uemail\r\n';
/* mail*/
mail('$email', '$subject', '$message', '$headers');
print 'Thank you. Your e-mail has been dispatched.';
?>