Is There A Way To Allow Only Registered Users To View Pics In My Joomla Site And Not Allow Direct Url Access? Free RapidShare Download

Is There A Way To Allow Only Registered Users To View Pics In My Joomla Site And Not Allow Direct Url Access?

July 26, 2009 under FAQ

I use Joomla for a photo gallery site. This site is accessible only by registered users. Now, the photos I upload are still available for direct url access ( www.mysite.com/joomla /images/asd.jpg). How do I prevent this? I would like to prevent any direct access to these images but, the registered users should be able to look at them from the site.

Search more about Is There A Way To Allow Only Registered Users To View Pics In My Joomla Site And Not Allow Direct Url Access?:

  • flashbird

Comments

2 Responses to “Is There A Way To Allow Only Registered Users To View Pics In My Joomla Site And Not Allow Direct Url Access?”
  1. MMoMMe says:

    I Don’t know..
    Maybe you can’t do that..

  2. Mike G says:

    Check out the following discussion:http://forum.joomla.org/viewtopic.php?f=…
    and more importantly this section in the Joomla FAQ:http://docs.joomla.org/Security_and_Perf…
    To allow only referrals from your site:
    step1) switch on rewite
    RewriteEngine On
    step 2) check that the refferal is not (!) from own site:
    RewriteCond %{HTTP_REFERER} !^http://(.+.)?your_site.com/ [NC]
    step 2 cont.) or not from an empty refferal (eg. bookmark?):
    RewriteCond %{HTTP_REFERER} !^$
    step 3) redirect them to a ‘no-hot-link’ image:
    RewriteRule .*.(jpe?g|gif|bmp|png)$ /images/no_hot_link.jpe [L]
    Or
    step 2) restrict certain sites:
    RewriteCond %{HTTP_REFERER} ^http://(.+.)?myspace.com/ [NC,OR]
    RewriteCond %{HTTP_REFERER} ^http://(.+.)?blogspot.com/ [NC,OR]
    RewriteCond %{HTTP_REFERER} ^http://(.+.)?livejournal.com/ [NC]
    and step 3) redirect them to display a 403 Forbidden code:
    RewriteRule .*.(jpe?g|gif|bmp|png)$ - [F]
    Checkout this page:http://altlab.com/htaccess_tutorial.html
    This ain’t the end of your search because ‘they’ will always find a way but it should help somewhat…
    All the best,
    Mike

Leave a Comment

If you want a pic to show with your comment, go get a gravatar!