I have a working mysql_query:
mysql_query("update products set buyers = buyers+$qtd where id=$pid") or die (pgs_log("erro linha 70 >".mysql_error()));
But then I insert the following query right after it, and it only execute the first one:
mysql_query("update products set pending = pending-$qtd where id=$pid") or die (pgs_log("erro linha 70 >".mysql_error()));
So, am I missing something?
echosql queries to the screen and see whether$qtdand$pidis still working, if it is not, check yourpgs_log(not sure what does it do). Is the query giving and error or is the page just loading the but database unchanged?where id=$pid")intowhere id='$id'"). i.e. enclose all those$varsin single quotes or yourmysql_real_escape_string's will be for naught.