Hello, I have the following code:
And most of it seems to be working, except the $points. What is happening is the $point value in recentredemptions is blank, so it says
and it is not awarding any points. What i tried to do before was use PHP multiply functions to multiple the CENTS into points, then using what it outputs and multiplying that by .7 (to get 70 percent) then flooring it so if it outputs a decimal it rounds down. But after I did that it did not input anything into the recent redemptions or points.
ALSO, how would i make it so when it goes in to look for the username in members, how woulc I make it so its not case sensitive?
THANKS FOR EVERYONES HELP!
Code:
<? include ("config.php"); //here we will use get variables. $snuid = $_GET['yti']; $campid = $_GET['campaignid']; $points = $_GET['rate']; $ip = $_SERVER['REMOTE_ADDR']; $sts = $_GET['credit']; if ($ip == "174.120.27.187" || "174.120.146.43" && $sts="1") { //INSERT LOGIC TO CREDIT POINTS TO USERS mysql_query("UPDATE members SET pokerpoints=pokerpoints+".$points." WHERE username='".$snuid."'"); mysql_query("UPDATE members SET totalpointsearned=totalpointsearned+".$points." WHERE username='".$snuid."'"); mysql_query("INSERT into recentpoints (message) VALUES ('$snuid has just cashed out for $rate Bankroll Bucks')"); mysql_close(); } else { die ("query failed"); } ?>
AnimalRoam has just cashed out for Bankroll Bucks
ALSO, how would i make it so when it goes in to look for the username in members, how woulc I make it so its not case sensitive?
THANKS FOR EVERYONES HELP!
Comment