• Page 1 of 1
  • 1
uCoz Community » uCoz Modules » Forum » Block Country's IP
Block Country's IP
DavidJr
Posts: 52
Reputation: 0

Message # 1 | 9:49 AM
How to block a Country's IP? I don't want any people from other country to access my forum, how to block it? and prevent them to view my site..
Post edited by DavidJr - Friday, 2012-07-13, 9:55 AM
Sunny
Posts: 9296
Reputation: 456

Message # 2 | 10:42 AM
DavidJr, if you know the IPs and have certain coding skills, it is possible though not easy.
I'm not active on the forum anymore. Please contact other forum staff.
DavidJr
Posts: 52
Reputation: 0

Message # 3 | 12:16 PM
Sunny, do you know it? cry it's make me loss
Sunny
Posts: 9296
Reputation: 456

Message # 4 | 2:25 PM
DavidJr, if I have time I'll try to translate the link I've sent you via PM. But I can't promise it.
I'm not active on the forum anymore. Please contact other forum staff.
DavidJr
Posts: 52
Reputation: 0

Message # 5 | 1:59 AM
Sunny, okay, i'll wait for it thanks for your help smile
chrislim2888
Posts: 1
Reputation: 0

Message # 6 | 4:11 PM
Hi David,
2 ways you can try.

1st - to implement the ip to location database that will determine the country of the visitor's IP and block it as per required.

2nd - block it via the htaccess. You can get the file at http://www.ip2location.com/free/visitor-blocker
Paradox
Old Guard
Posts: 3284
Reputation: 145

Message # 7 | 0:30 AM
chrislim2888, DavidJr, unfortunately neither of these methods will work with uCoz sites - the first may but it would most liekly require the use of PHP scripts.
Jack of all trades in development, design, strategy.
Working as a Support Engineer.
Been here for 13 years and counting.
DavidJr
Posts: 52
Reputation: 0

Message # 8 | 3:33 PM
So i must try the second one?

I've download the file from here http://www.ip2location.com/free/visitor-blocker

So what i must do with the .txt file?
Post edited by DavidJr - Sunday, 2012-07-15, 3:35 PM
Paradox
Old Guard
Posts: 3284
Reputation: 145

Message # 9 | 3:51 PM
Quote (Paradox)
nfortunately neither of these methods will work with uCoz sites


Meaning the first nor the second will work.

1) It may be possble using PHP/advanced JavaScript but that is beyond the duties of the forum staff.
2) .htaccess files don't work in cohesion with uCoz sites as far as I am aware so the second method will not work.

My best advice is to wait for Sunny to translate whichever she sent to you via PM. wink

Jack of all trades in development, design, strategy.
Working as a Support Engineer.
Been here for 13 years and counting.
DavidJr
Posts: 52
Reputation: 0

Message # 10 | 10:51 AM
I don't understand with this code cry
kinglyanas
Posts: 1
Reputation: 0

Message # 11 | 10:20 AM
Did anyone can help me, my question is that how can i locate .htaccess file in my file manager...??? Or did i craet this file by self...??
joexyz
JOE-vascript
Posts: 1770
Reputation: 78

Message # 12 | 11:57 AM
kinglyanas, you can't. For starters, uCoz is based on uServ, a modified version of the nginx web server. nginx does not have .htaccess files, that is only available on Apache web servers.

Depending on what exactly you want to do there could be other workarounds. Please elaborate on your question.

hey i'm joe and i do not work for the company anymore, please contact other staff or tech support
icon by ch-chau

sometimes i lurk here
uCoz Community » uCoz Modules » Forum » Block Country's IP
  • Page 1 of 1
  • 1
Search: