logo
Apache Lounge
Webmasters

 

About Forum Index Downloads Search Register Log in RSS X


Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.

or

Bitcoin

A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
Post new topic   Forum Index -> Apache View previous topic :: View next topic
Reply to topic   Topic: URL Forwarding
Author
djc



Joined: 04 Dec 2007
Posts: 37

PostPosted: Fri 30 Jan '09 7:09    Post subject: URL Forwarding Reply with quote

Hi Everyone,

I have a question on how to forward a URL, specifically one out of my control. If someone has directed a URL (www.example.com) to a directory on my site (http://www.anotherexample.com/forums) , how can I deny access?

Since the URL is being forwarded, is the referrer information still going to show the originally requested URL or will it show the forwarded URL?

Am I left with contacting the host and asking for them to remove the forwarding?

Thanks!
Back to top
James Blond
Moderator


Joined: 19 Jan 2006
Posts: 7371
Location: Germany, Next to Hamburg

PostPosted: Sun 01 Feb '09 13:20    Post subject: Reply with quote

You could use a antihotlinking rewrite rule

Well this is only against hotlinking for images, but I'm sure you can modify it for your needs.

Code:

RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http://www.anotherexample.com/.*$ [NC]
RewriteRule .*\\.(gif|jpg|png)$ http://www.anotherexample.com/images/replacement.gif [R,NC]
Back to top


Reply to topic   Topic: URL Forwarding View previous topic :: View next topic
Post new topic   Forum Index -> Apache