First you get a list of IPs for the country that you for whatever reason wish to ban, http://www.phptutorial.info/iptocountry/the_script.html you should be able to use their script's IP file. Then add the following type of line to your .htaccess or apache server config file:
Code:
Deny from 256.256.256.256
__________________
PHP Code:
<?php echo "Hello World"; ?>
HTML Code:
<html><head><title>Hello World</title></head><body><p>Hello World</p></body></html>
|