View file znak_otzuv(mysql)/votefoto.php
<?php require("db.php"); if($id) { $id=intval($id); $q = @mysql_query("select `counter`,`nick`,`name` from `users` where id='".$id."';"); $data = @mysql_fetch_array($q); $counter = $data['counter']+1; @mysql_query("update `users` set counter='".$counter."' where id='".$id."';");} if($data['nick']) { header("Location: ./index.php?nick=".$data['nick'].""); } @mysql_close(); ?>