You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near '.60.77 AND zeit > 1135484783' at li
Code:
<? include ("../admin/konfig.php"); $id = $_GET['id']; dbcon(); $time = time(); $ip = getenv ("REMOTE_ADDR"); $sperre = $time - 15000; $aufruf = "SELECT * FROM ip Where id=".$id." AND ip=".$ip." AND zeit > ".$sperre.";"; $aufruf3 = "SELECT * FROM suche Where ID=".$id.";"; $aufruf1 = mysql_query ($aufruf) OR die (mysql_error()); $aufruf2 = mysql_num_rows ($aufruf1) OR die (mysql_error()); $aufruf4 = mysql_query ($aufruf3) OR die (mysql_error()); $aufruf5 = mysql_fetch_assoc($aufruf4); $aufruf10 = "DELETE FROM ip WHERE zeit < ".$sperre.";"; switch ($aufruf2) { case 1: $unw = mysql_query($aufruf10) OR die (mysql_error()); header("Location: ".$aufruf5["link"].""); case 0: $aufruf5["count"]++; $aufruf6 = "INSERT INTO suche (count) VALUES (".$aufruf5["count"].");"; $aufruf7 = mysql_query($aufruf6) OR die (mysql_error()); $aufruf8 = "INSERT INTO ip (id,ip,zeit) VALUES (".$id.",".$ip.",".$time.");"; $aufruf9 = mysql_query($aufruf8) OR die (mysql_error()); $unw1 = mysql_query($aufruf10) OR die (mysql_error()); header("Location: ".$aufruf5["link"]."");; } ?>
Kommentar