Every forum suffers from spam either in the start or after it has started gaining users. Sometimes spammers use bots with multiple IP’s and when you know those IP’s, you can ban them so that you can prevent spam easily.
MyBB has this feature inbuilt and it is very useful. Yet lot of people don’t know about this and go for various custom plugins which may or may not be required. In this tutorial we will use the Ban IP feature of MyBB to prevent spam. I have previously shared a tutorial on stopping forum spam which includes the list of plugins that are very useful in prevention of forum spam.
This tutorial is simple and is easy to follow. Follow these steps to ban IP to prevent spam in MyBB;
1. Go to Your Admin CP > Configuration > Banning (From left hand side). You will see a page like this
2. You will see a box where you can add IP address, write the IP address of the spammer and MyBB has banned that IP.
3. Now suppose you want to ban multiple IP’s or a range, then enter the 127.0.0.* (notice the *, it is a wildcard that says anything in this area). This will ban all the IP’s In that particular range.
Suppose you want to use a different method to ban IP apart from MyBB way. We can use .htaccess to also ban IP. Simple steps to do so :-
1. Go to cpanel and create a file called .htaccess
2. Edit that file and write below code in that
order allow,deny deny from 255.0.0.0 deny from 188.8.131.52 allow from all
255.0.0.0 and 184.108.40.206 are the IP of spammer. You can add as many IP you want. Notice
how easy MyBB makes it for you.
Hope this tutorial helps you ban IP to prevent spam in MyBB