Validate referrer to access directory script?

3 replies
There are lots of solutions to validate access to certain pages and there are lots of solutions to block access by ip or referrer validation to pages...

I am looking for a simple solution that will only allow access to a directory (not page) once the referring domain is validated not the referring page either just the domain.

Anyone know of something like this?
#access #directory #referrer #script #validate
  • Profile picture of the author Wilson Mattos
    You can do this via the .htaccess file.

    Google for "hot linking prevention technique apache htaccess" and it will be the first article (sorry cannot copy/paste URL on iPhone).

    That article will show you what to add to validate the referring domain or deny access.

    Wil
    {{ DiscussionBoard.errors[411136].message }}
  • Profile picture of the author Dmitry
    If I understand correctly what you want to do and referrer spoofing isn't a concern I suppose you might use an .htaccess file...

    In particular something like this:

    Preventing Image Bandwidth Theft With .htaccess (thesitewizard.com)

    If you can't make it on your own - let me know and I'll try to toy around with it.
    {{ DiscussionBoard.errors[411140].message }}

Trending Topics