Nella query di delete ho dei problemi infatti le clausole deve c'è il not in danno sempre vero anche se id o idaut compaiono nella lista temp e mi si cancella tutto.
Come devo fare?
Grazie
codice:
$st=mysql_query("SELECT ip FROM presenti where logout=0",$conn) or die(mysql_error());
$temp=array();
while ($row=mysql_fetch_array($st))
$temp[]=$row['ip'];
$temp=implode(",",$temp);
print $temp;
$st=mysql_query("DELETE FROM contatto WHERE (id NOT IN ('".$temp."')) and (idaut NOT IN ('".$temp."'))",$conn) or die("ciao".mysql_error());