ok im making a browser based game and i wnated to add stocks as one of the feature so i made a random function that ran on a cron to control the up down value and now im trying to add purchasing of stocks here is my code
//buy stock #1
if ($_GET['buy']==true1){
if($a<=$money){
$st = $_1stock + 1;
$oney = $money-$a;
$val = $a*.10;
$net = $networth+$val;
$stock = "UPDATE UserDetails set networth='$net', money='$oney', 1='$st', value1='$a'
where ID='$id'";
mysql_query($stock) or die ("Could Not Buy Stock");
echo "You Just Bought Stock #1 for $$a";
}
else {
echo "You There Aint Got Enough Money";
}
}
//end stock #1
now all the varibles are being pulled from a config.php page which i have included farther up in this page.
When i hit the submit button which sets buy==true1 i get the message Could Not Buy Stock not sure whats wrong with the script any help would be greatly appreciated since im on a deadline on the game