Ver Mensaje Individual
  #4 (permalink)  
Antiguo 01/10/2007, 05:50
kero-dono
 
Fecha de Ingreso: octubre-2007
Ubicación: agua dulce, veracruz
Mensajes: 22
Antigüedad: 16 años, 7 meses
Puntos: 1
Re: Comparar datos de un archivo txt (IP del visitante)

mmm trata con un carriage return /r
Código PHP:
<?php  

$Fich 
"ip.txt"
$userIp $_SERVER["REMOTE_ADDR"]; 

$fh fopen($Fich'a') or die("Error!!"); 
fwrite($fh$userIp "\r\n"); 
fclose($fh); 

$ips file($Fich); 

$count 0
foreach ( 
$ips as $ip 

    if ( 
$ip == $userIp 
        
$count++; 


if ( 
$count == 
    print 
'Hola'

?>