Делаю мод для соц сети Кота
Написал вот такой код
[code]
case \'ok\':
$select = abs(intval($_GET[\'select\']));
if ($select == 1) $price = $user[\'balls\'] - 200;
if ($select == 2) $price = $user[\'balls\'] - 180;
if ($select == 3) $price = $user[\'balls\'] - 150;
if ($select == 4) $price = $user[\'balls\'] - 160;
if ($select == 5) $price = $user[\'balls\'] - 100;
if ($select == 6) $price = $user[\'balls\'] - 100;
if ($select == 7) $price = $user[\'balls\'] - 80;
if ($select == 8) $price = $user[\'balls\'] - 80;
if ($select == 9) $price = $user[\'balls\'] - 80;
if ($select == 10) $price = $user[\'balls\'] - 80;
if ($select == 11) $price = $user[\'balls\'] - 80;
if ($select == 12) $price = $user[\'balls\'] - 80;
if ($select == 13) $price = $user[\'balls\'] - 80;
if ($select == 14) $price = $user[\'balls\'] - 80;
if ($select == 15) $price = $user[\'balls\'] - 80;
if ($select == 16) $price = $user[\'balls\'] - 80;
if ($select == 17) $price = $user[\'balls\'] - 80;
if ($select == 18) $price = $user[\'balls\'] - 80;
if ($select == 19) $price = $user[\'balls\'] - 80;
if ($select == 20) $price = $user[\'balls\'] - 80;
if ($select == 21) $price = $user[\'balls\'] - 80;
if ($select == 22) $price = $user[\'balls\'] - 80;
if ($select >= 1 AND $select <= 22) {
if ($price >= 0) {
echo \'Загляните в свою анкету<br/>
<a href=\"/anketa.php\">В анкету →</a>\';
mysql_query(\"UPDATE `pets` SET `pet_id` = \'$select\', `time` = \'$realtime\' WHERE `user_id` = \'\".$user[\'id\'].\"\'\"
;
mysql_query(\"UPDATE `users` SET `balls` = \'$price\' WHERE `id` = \'\".$user[\'id\'].\"\'\"
;
[/code]
Вот но в таблице pet_id значение не меняеться!В чем проблема?