Support » Plugin: Private Only » Protect Upload folder

  • At the moment the plugin doesn’t protect the files in the upload folder. I know, this is already known.

    But I found the following script as solution which works for me:

    It’s basically a PHP script, which checks if you are logged in or not. If not it redirects to the login page, if yes it delivers the file(s). It’s called by the .htaccess file using

    RewriteCond %{REQUEST_FILENAME} -s
    RewriteRule ^wp-content/uploads/(.*)$ dl-file.php?file=$1 [QSA,L]

    Maybe it’s possible to use this for this plugin?

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘Protect Upload folder’ is closed to new replies.