Jump to content


Photo

For domain, deny and replace with image


  • Please log in to reply
9 replies to this topic

#1 johnnyk

johnnyk
  • Members
  • PipPipPip
  • Advanced Member
  • 126 posts

Posted 06 September 2006 - 12:35 AM

I don't know much about .htaccess and I never learned about mod_rewrite or whatever that fancy thing is.

What I want to do is deny from a certain domain. Instead of a 403 page, I want anyone who is from that domain to see an image when they go to my site. Any idea how that would happen?
Rediscover the Web:
<a href="http://www.spreadfir...;t=219"></a><br />

#2 oldmanice

oldmanice
  • Members
  • PipPipPip
  • Advanced Member
  • 134 posts
  • LocationIn Your Garden At Night

Posted 06 September 2006 - 12:55 AM

Your going to have to set there ip address as deny and block them from your apache page. Once this is done update the error 404 page and put in the picture.
Join my Froums www.phpbbplanet.com/darkwinter

#3 johnnyk

johnnyk
  • Members
  • PipPipPip
  • Advanced Member
  • 126 posts

Posted 06 September 2006 - 01:35 AM

But I want the blocked domains to get a different 403 (or 404 or whatever it is) than everyone else.
Rediscover the Web:
<a href="http://www.spreadfir...;t=219"></a><br />

#4 oldmanice

oldmanice
  • Members
  • PipPipPip
  • Advanced Member
  • 134 posts
  • LocationIn Your Garden At Night

Posted 06 September 2006 - 01:58 AM

Yes you have to update your error 404 pages for those domians only.
Join my Froums www.phpbbplanet.com/darkwinter

#5 johnnyk

johnnyk
  • Members
  • PipPipPip
  • Advanced Member
  • 126 posts

Posted 06 September 2006 - 02:07 AM

Isn't there a way to do it using something like:
RewriteCond %{REMOTE_HOST} whatever
RewriteRule whatever
Rediscover the Web:
<a href="http://www.spreadfir...;t=219"></a><br />

#6 oldmanice

oldmanice
  • Members
  • PipPipPip
  • Advanced Member
  • 134 posts
  • LocationIn Your Garden At Night

Posted 06 September 2006 - 02:40 AM

johnnyk sorry mate I really dont know what you want to do now Im not the right person for that.
Join my Froums www.phpbbplanet.com/darkwinter

#7 johnnyk

johnnyk
  • Members
  • PipPipPip
  • Advanced Member
  • 126 posts

Posted 06 September 2006 - 03:09 AM

OK I'll try to make sense. I want any visitors from a certain host to see an image instead of the website. Is there a way to do that using only .htaccess?
Rediscover the Web:
<a href="http://www.spreadfir...;t=219"></a><br />

#8 oldmanice

oldmanice
  • Members
  • PipPipPip
  • Advanced Member
  • 134 posts
  • LocationIn Your Garden At Night

Posted 06 September 2006 - 03:15 AM

Do you mean that those certian users that you want blocked you want them to see a image. Yes you have to modifey the 404 error page for those users and put the image in the 404 error page.


Join my Froums www.phpbbplanet.com/darkwinter

#9 ober

ober
  • Staff Alumni
  • Advanced Member
  • 5,337 posts
  • LocationEast Coast, USA

Posted 06 September 2006 - 01:08 PM

Certain comments and posts have been deleted from this thread.  Let's try to stay on topic and only post when you have something valid to add to the conversation.  Thanks.

Info: PHP Manual


#10 oldmanice

oldmanice
  • Members
  • PipPipPip
  • Advanced Member
  • 134 posts
  • LocationIn Your Garden At Night

Posted 08 September 2006 - 06:29 PM

johnnyk,
Did you manage to get it working in the end?

Join my Froums www.phpbbplanet.com/darkwinter




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users