Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Post New Thread Reply

Register GFY Rules Calendar Mark Forums Read
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed.

 
Thread Tools
Old 03-12-2006, 09:16 PM   #1
pr0
rockin tha trailerpark
 
pr0's Avatar
 
Industry Role:
Join Date: May 2001
Location: ~Coastal~
Posts: 23,088
htaccess help!!!

Heres what my htaccess looks like on a search engine cloaked domain i have going to a sponsor

RewriteEngine on
RewriteCond %{HTTP_HOST} ^domain.com$ [OR]
RewriteCond %{HTTP_HOST} ^www.domain.com$
RewriteRule ^(.*)$ http://spsonsor.com/?111111 [R=301,L]


Now what i need to do, is block out all .gov, .us, .org & anything with the prefix k12....its part of my campaign to keep kids & people using public computers off my porn sites.

So how would i add that to my htaccess?
pr0 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 03-12-2006, 09:18 PM   #2
fris
Too lazy to set a custom title
 
fris's Avatar
 
Industry Role:
Join Date: Aug 2002
Posts: 55,372
you can use the deny rules
__________________
Since 1999: 69 Adult Industry awards for Best Hosting Company and professional excellence.


WP Stuff
fris is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 03-12-2006, 09:19 PM   #3
dissipate
The Dirty Frenchman
 
dissipate's Avatar
 
Industry Role:
Join Date: Nov 2005
Location: Lost Angeles
Posts: 8,904
order allow,deny
deny from .gov
deny from .us
deny from .k12 (im not sure where the k12 is in the IP)
allow from all


To block a specific IP, just type in the full IP address - e.g. 192.168.1.1
To block a range of IP's, use a partial IP address - e.g. 192.168.1
To block a country, type in the tail extension - e.g. .au

mind you, this isnt going to block anything if thier IP doesnt reverse correctly

Last edited by dissipate; 03-12-2006 at 09:22 PM..
dissipate is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 03-12-2006, 09:19 PM   #4
pr0
rockin tha trailerpark
 
pr0's Avatar
 
Industry Role:
Join Date: May 2001
Location: ~Coastal~
Posts: 23,088
yea...i don't know shit about linux man

can someone write it out for me?
pr0 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 03-12-2006, 09:26 PM   #5
dissipate
The Dirty Frenchman
 
dissipate's Avatar
 
Industry Role:
Join Date: Nov 2005
Location: Lost Angeles
Posts: 8,904
Quote:
Originally Posted by pr0
yea...i don't know shit about linux man

can someone write it out for me?
Hope that helped.
dissipate is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 03-12-2006, 09:31 PM   #6
pr0
rockin tha trailerpark
 
pr0's Avatar
 
Industry Role:
Join Date: May 2001
Location: ~Coastal~
Posts: 23,088
Quote:
Originally Posted by dissipate
Hope that helped.
yea should i paste it on top of my code i already have, or below?
pr0 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 03-12-2006, 09:44 PM   #7
mikeyddddd
Viva la vulva!
 
mikeyddddd's Avatar
 
Join Date: Mar 2003
Location: you can't please everyone, so you got to please yourself
Posts: 16,557
I use this:

RewriteCond %{REMOTE_HOST} .*\.gov$ [NC,OR]
RewriteCond %{REMOTE_HOST} .*\.us$ [NC,OR]
RewriteCond %{HTTP_REFERER} .*\.gov$ [NC,OR]
RewriteCond %{HTTP_REFERER} .*\.gov/.* [NC,OR]
RewriteCond %{HTTP_REFERER} .*\.us$ [NC,OR]
RewriteCond %{HTTP_REFERER} .*\.us/.* [NC]
RewriteRule .* http://www.www-web.com/ [R,L]
mikeyddddd is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 03-12-2006, 09:54 PM   #8
pr0
rockin tha trailerpark
 
pr0's Avatar
 
Industry Role:
Join Date: May 2001
Location: ~Coastal~
Posts: 23,088
so would it be......

RewriteEngine on
RewriteCond %{HTTP_HOST} ^domain.com$ [OR]
RewriteCond %{HTTP_HOST} ^www.domain.com$
RewriteRule ^(.*)$ http://spsonsor.com/?111111 [R=301,L]
RewriteCond %{REMOTE_HOST} .*\.gov$ [NC,OR]
RewriteCond %{REMOTE_HOST} .*\.us$ [NC,OR]
RewriteCond %{HTTP_REFERER} .*\.gov$ [NC,OR]
RewriteCond %{HTTP_REFERER} .*\.gov/.* [NC,OR]
RewriteCond %{HTTP_REFERER} .*\.us$ [NC,OR]
RewriteCond %{HTTP_REFERER} .*\.us/.* [NC]
RewriteRule .* http://www.www-web.com/ [R,L]
pr0 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 03-12-2006, 10:15 PM   #9
pr0
rockin tha trailerpark
 
pr0's Avatar
 
Industry Role:
Join Date: May 2001
Location: ~Coastal~
Posts: 23,088
bump bump
pr0 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 03-12-2006, 10:42 PM   #10
Decadawn
Confirmed User
 
Decadawn's Avatar
 
Industry Role:
Join Date: Feb 2002
Location: Montreal
Posts: 1,286
Quote:
Originally Posted by dissipate
order allow,deny
deny from .gov
deny from .us
deny from .k12 (im not sure where the k12 is in the IP)
allow from all
doesn't putting "allow from all" at the end cancel all the denies above?
Decadawn is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 03-12-2006, 10:51 PM   #11
pr0
rockin tha trailerpark
 
pr0's Avatar
 
Industry Role:
Join Date: May 2001
Location: ~Coastal~
Posts: 23,088
anyone here able to give me a straight answer?
pr0 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 03-12-2006, 11:00 PM   #12
pr0
rockin tha trailerpark
 
pr0's Avatar
 
Industry Role:
Join Date: May 2001
Location: ~Coastal~
Posts: 23,088
damn this sucks
pr0 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Post New Thread Reply
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >

Bookmarks
Thread Tools



Advertising inquiries - marketing at gfy dot com

Contact Admin - Advertise - GFY Rules - Top

©2000-, AI Media Network Inc



Powered by vBulletin
Copyright © 2000- Jelsoft Enterprises Limited.