Ok im trying to block traffic from certian ip ranges.. and anyway i still want the users to be able to see my bidvertiser ads and some content.. but not all content.. so i made this.. <?php function checkIP($ip_to_match, $ip_array) { if (is_array($ip_array)) { foreach ($ip_array as $ip) { if (strstr($ip_to_match, $ip) && strpos($ip_to_match, $ip)==0) { return true; } } } return false; } $ban_array = array( '216.47.55.141', '72.47.147', '62', '62', '24', '84', '81', '82', '83', '86', '12', '125', '149', '89' ); if (checkIP($_SERVER['REMOTE_ADDR'], $ban_array)) { echo "This page is not accessable for users in your area. ."; exit; } ?> see where it says echo "This page is not accessable for users in your area. ."; I want to place some bidvertiser code there but with out editing the code
if (checkIP($_SERVER['REMOTE_ADDR'], $ban_array)) { echo "This page is not accessable for users in your area. ."; ?> STANDARD CODE CAN GO HERE AS YOU CAN CLOSE PHP IN THE MIDDLE OF LOOPS OR CONDITIONAL TESTS AND RESUME LATER <?php exit; } ?>