AlabamaHit Posted March 28, 2008 Posted March 28, 2008 Ok. Let me start by saying what I'm trying to do. I am trying to make it where a users when they are buying a house they do not have to sell there old one. I have a forumla but it don't seem to work. $pr=(int) ($np['hPRICE']); $price=(int) ($np['hPRCE'] - $pr); I have also tried. $pr=$mp['hPRICE']; $price=$mp['hPRCE'] - $pr; Also have tried $pr=($mp['hPRICE']); $price=($mp['hPRCE'] - $pr); The query before this to call the houses is. $mpq=mysql_query("SELECT * FROM houses WHERE hWILL={$ir['maxwill']}",$c); $mp=mysql_fetch_array($mpq); There are more querys. As if you have v1 you can look in your estate page and see. But they don't have anything to do with what I'm trying to do, lol. This is the query I am running to buy the house. mysql_query("UPDATE users SET money=money-$price, will=0, maxwill={$np['hWILL']}, WHERE userid=$userid",$c); What it is not doing is it's not taking the money from the user for the house. Just wondering if anyone might have an idea what I'm doing wrong. I really don't see what I'm doing wrong, lol. Thanks for the help. Quote
AlabamaHit Posted March 28, 2008 Author Posted March 28, 2008 Re: Houses Dang....I can't believe I missed that...Your right, lol...I have to come up with another forumla to call the price of the house they are buying minus the price of the house they have already. Quote
AlabamaHit Posted March 29, 2008 Author Posted March 29, 2008 Re: Houses i still cant get it, :x Quote
AlabamaHit Posted March 30, 2008 Author Posted March 30, 2008 Re: Houses Parse error: syntax error, unexpected T_STRING, expecting ']' in /home/hoopitne/public_html/estate.php on line 23 thats is on the $price = $np['hPRICE'] - $ch->hPRICE; I have tried a number of things and can't get that error gone....Man I must be getting worst at the coding, lol Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.