Rolf: Probleme mit Anführungszeichen

Beitrag lesen

Das ist das ganze Skript:

<?php
include('sql.php');
$table='statistik';
$ip=$REMOTE_ADDR;
$browser=$HTTP_USER_AGENT;
$ref=$HTTP_REFERER;
$date=date('d.m.Y');
$query=mysql_query('SELECT id FROM '.$table.' WHERE ip='.$ip) or die (mysql_error());
if(mysql_num_rows($query)>0){
 $this_time=time();
 $querys=mysql_query('SELECT datum,zeit FROM '.$table.' WHERE ip='.$ip) or die (mysql_error());
 $row=mysql_fetch_array($querys) or die (mysql_error());
 if($date=$row['datum']&&$this_time<($row['zeit']+14400)){
   die();
 } else {
 $dummy=mysql_query('INSERT INTO '.$table.' (ip,browser,ref,datum,zeit) VALUES ('.$ip.','.$browser.','.ref.','.$date.','.$this_time) or die (mysql_error());
 }
}
?>