Hey guys we want to make a lava code where it wish a member happy birthday via email
ive already added some codes together but dnt know if its right anyone can help me complete it please
$tolog = true;
{
$noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users where month(`birthday`) = month(curdate()) and dayofmonth(`birthday`) = dayofmonth(curdate());"));
if($noi[0]!=0){
$sql = mysql_fetch_array(mysql_query("SELECT id, name, birthday FROM ibwf_users where month(`birthday`) = month(curdate()) and dayofmonth(`birthday`) = dayofmonth(curdate()) ORDER BY RAND() LIMIT 1"));
$uage = getage($sql[2]);
$lnk = "<hr />Happy Birthday<br/><a href=\"index.php?action=viewuser&who=$sql[0]\">$sql[1]</a>";
echo "$lnk<br/>Hope U have A Wonderful Day<br/>";
}
}
if($tolog)
{
$msg = "\n Happy Birthday: ".$uid." \n http://lava-codings.uk.to Wish u a happy Birthday and tanx for being our member \n\n Thank You\n dnt forget to come and say hey";
$subj = "Whises from lava-codings.uk.to";
$headers = 'From: noemail@lava-codings.uk.to' . "\r\n" .
'Reply-To: noreply@lava-codings.uk.to' . "\r\n" .
'X-Mailer: PHP/' . phpversion();
mail($email, $subj, $msg, $headers);
echo "<a href=\"login.php?loguid=$uid&logpwd=$pwd\"><img src=\"images/home.gif\" alt=\"*\"/>";
echo "Login</a>";
}
Jacques jacques@gw-designs.co.za http://coding.biz.tm Come join and lets make it a place to learn all the noobies how to code
NEVER FORGET TO CLICK THE TANX BUTTON IF U LIKE WHAT IM SHARING OR HELPING WITH