hi am having problems with this it just doesnt work
[code=php]
<?php
$ip = $_SERVER[“REMOTE_ADDR”];
$banned = file(“ips.php”);
$num = 0;
while(array_key_exists($num, $banned)) {
if($banned[$num] == $ip) {
exit(“You Have Been Banned From This Chat Room1″);
} else {
echo $banned[$num].”<br>”;
}
$num++;
}
if(in_array($ip, $banned)) {
exit(“You Have Been Banned From This Chat Room2″);
}
echo $ip.”<br>”;
print_r($banned);
?>
but why? simple simple php, i have just coded a 78kB command file for this and now i come to do something comparativly trivial ‘IP blocking’ its not working, any ideas?
[url]http://www.richardturner.com/chat/ip.php