![]() | | ||||||||
| | #1 |
| HyperActive Warrior War Room Member Join Date: Jun 2008 Location: , , .
Posts: 266
Thanks: 11
Thanked 4 Times in 4 Posts
|
Hi warriors I want to know how to block a person from viewing my site? can any body explain in detail as i don't know any thing about it? Please help me warriors. I am using wordpress so is there anyone knows how to block a person? James |
| | |
| | #2 |
| HyperActive Warrior War Room Member Join Date: Sep 2008 Location: East Coast
Posts: 136
Thanks: 4
Thanked 15 Times in 8 Posts
|
maybe you can be more specific. are you refering to one particular person? or are you referring to for members only? or are you referring the whole world not be able to see your site? reason why I'm asking, the approach is different. the first one is bit difficult to do. the second and third one are quite easy. if you can clarify, maybe we can help out the details. |
| | |
| | #3 |
| Senior Warrior Member War Room Member Join Date: Sep 2007 Location: Louisville, KY
Posts: 1,131
Thanks: 41
Thanked 90 Times in 71 Posts
|
If its a public site, about the only way to block them is by blocking their ip address. This will only work for so long if they have a dynamic ip. Eventually it will change and then they will be able to access your site again. If they have a static ip this will work really well. If they are using proxies to view your site, then you will have to keep blocking proxy ip addresses. That is about all you can do to block them, unless they are using a user name and password to login to your site. If that is the case, then you could setup a fake site and redirect their login to the fake site. IT Security people use this method to prevent DDOS attacks and things like that. It is referred to as using a "Honey Pot". Hope that helps. Dennis |
| | |
| | |
| | #4 | |
| Senior Warrior Member War Room Member Join Date: Dec 2005 Location: Hubbard, Ohio, USA.
Posts: 4,387
Thanks: 333
Thanked 113 Times in 89 Posts
| Quote:
James, If you go into your host cpanel, you should see an icon with the words "Deny IP address" or something similar. Just add the IP address or block of addresses you want to deny. Once their IP address is added to this list, your server will deny it, and they cannot view your site or blog. Just remember, if their IP address changes or if they are using a proxy, you will have to re-enter their new IP addresses. Proxies are a bit difficult to block, but you can block an entire IP block or group in one swipe. | |
| | |
| | #5 |
| HyperActive Warrior War Room Member Join Date: May 2009 Location: Bradford, UK
Posts: 204
Thanks: 17
Thanked 31 Times in 26 Posts
|
If you know their IP address you can block them using .htaccess - If you don't know, the .htaccess file is a file that lives in the directory of your website where your files are than can control how your site behaves (put simplistically!). Check the root www directory. If there isn't a .htaccess file there, you can create one using your favourite text editor. It's a hidden file so make sure your ftp program is set to show hidden files. Put it in the same directory as your index.php or index.html file. If there is, add it to the end of the file. In the .htaccess file put the following: <Files 403.shtml> order allow,deny allow from all </Files> deny from xxx.xxx.xxx.xxx where xxx.xxx.xxx.xxx is the ip address you want to ban. If you want to ban more than one ip address, add more deny from lines. |
| | |
| | |
| | #6 |
| Chick Magnet Join Date: May 2009 Location: Kentucky, USA
Posts: 193
Thanks: 18
Thanked 22 Times in 19 Posts
|
You can block anything you want to with the following code in your .htaccess file. Use the following code : <Limit GET POST> #The next line modified by DenyIP order allow,deny #The next line modified by DenyIP #deny from all allow from all </Limit> <Limit PUT DELETE> order deny,allow deny from all </Limit> <Files 403.shtml> order allow,deny allow from all </Files> SetEnvIfNoCase User-Agent .*Twiceler.* bad_bot SetEnvIfNoCase User-Agent .*VoilaBot BETA 1.2.* bad_bot SetEnvIfNoCase User-Agent .*libwww-perl/5.805.* bad_bot SetEnvIfNoCase User-Agent .*Java/1.5.0_11.* bad_bot SetEnvIfNoCase User-Agent .*Sogou web spider/3.0.* bad_bot SetEnvIfNoCase User-Agent .*psbot.* bad_bot SetEnvIfNoCase User-Agent .*Exabot.* bad_bot SetEnvIfNoCase User-Agent .*Charlotte/1.0b.* bad_bot SetEnvIfNoCase User-Agent .*boitho.com-dc.* bad_bot SetEnvIfNoCase User-Agent .*ajSitemap.* bad_bot SetEnvIfNoCase User-Agent .*bot/1.0.* bad_bot SetEnvIfNoCase User-Agent .*panscient.com.* bad_bot SetEnvIfNoCase User-Agent .*Java/1.6.0_11.* bad_bot SetEnvIfNoCase User-Agent .*WebDataCentreBot/1.0.* bad_bot SetEnvIfNoCase User-Agent .*Java.* bad_bot SetEnvIfNoCase User-Agent .*SapphireWebCrawler.* bad_bot SetEnvIfNoCase User-Agent .*Yandex.* bad_bot SetEnvIfNoCase User-Agent .*Baiduspider.* bad_bot SetEnvIfNoCase User-Agent .*Rankivabot.* bad_bot SetEnvIfNoCase User-Agent .*DBLBot/1.0.* bad_bot order allow,deny deny from env=bad_bot allow from all These are the bots I'm banning right now. IP address does not matter - they will still be banned. As you find new ones just keep adding new lines to the banned list. As you add new lines remember to keep the .* at the front and ending of the item you want blocked. |
| Collectible Dolls Shop, Nursing Scrubs Shop, Best Shopping Center, Sports Memorabilia Deals Eat More Beans - America Needs The Gas. | |
| | |
| | #7 |
| Software Developer War Room Member Join Date: Feb 2007 Location: Ohio , USA.
Posts: 2,273
Thanks: 416
Thanked 408 Times in 250 Posts
|
If you want to just block individuals (instead of building a membership type site), there is a plugin for WP that will do this. It's called "WP-Ban"
|
|
-Jason
| |
| | |
![]() |
|
| Tags |
| block, site, viewing, visitor |
| Thread Tools | |
| |
![]() |