I created these htaccess and deny.php scripts to easily block access to your website. The script allows you to quickly enter an IPv4 or IPv6 address and automatically adds the domain associated with it.
Please download and unpack this in the public folder of your website's root directory. Remember to back up your current .htaccess file. Then navigate to yourdomain.com/deny.php and add the IP address you wish to block from accessing your website. Once they are on the deny list, they will no longer be able to view your website and will be redirected to your Deny blackhole.
Great to use with wordpress or opencart or any other PHP systems.