I use this
code:
<?php
function ip_check()
{
// Addresses to block.
$block_ip[] = '203.217.64.174';
// Check current IP.
if (in_array($_SERVER['REMOTE_ADDR'], $block_ip))
{
return false;
}
else
{
return true;
}
}
?>
Then in your index file or whatever put this include
code:
<?php include 'bannedip.php'; if (!ip_check())
{
header( "Location: http://ng.audiodragon.net/bannage.php");
}
?>
Change the header location bit to the redirect site, bannedip.php to the name of your script.
You can also just display text using the echo command..