Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Contributor Pippin Williamson

    (@mordauk)

    That’s correct, but we have a condition in our htaccess file to prevent the image from being blocked.

    Is the image not showing up properly in the directory?

    Thread Starter Diana Burduja

    (@diana_burduja)

    In my .htaccess file there were only the following rules:

    Options -Indexes
    deny from all

    Order Allow,Deny
    Allow from all

    I don’t know about how come I got to have these rules instead of the right ones.

    Since this was a problem specific to my installation I’ll close this topic. Sorry for the misunderstanding.

    Plugin Contributor Pippin Williamson

    (@mordauk)

    In Downloads > Settings > Misc, change your Download Method to “Forced”.

    Does that resolve it?

    Thread Starter Diana Burduja

    (@diana_burduja)

    Hi, I found out how come I was having those rules in my .htaccess file.

    When you install the plugin and it doesn’t manage to create the .htaccess file, it outputs a notice in the admin with the message:

    If this warning continues to appear, create a file called ".htaccess" in the <strong>/var/www/website.com/wp-content/uploads/edd</strong> directory, and copy the following into it:

    The .htaccess rules are output correctly, but the <FilesMatch> directive is considered an HTML tag and is simply not shown.

    The rules that I had in the .htaccess file two months ago were there because I copied them by hand from the admin notice and put them in there.

    The solution is simple: just pass the edd_get_upload_dir() through an htmlentities before outputing the admin notice.

    Thread Starter Diana Burduja

    (@diana_burduja)

    Sorry, I meant: pass the edd_get_htaccess_rules() through an htmlentities before outputing the admin notice.

    Plugin Contributor Pippin Williamson

    (@mordauk)

    Ah! Thanks for sharing!

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Featured image in the protected directory’ is closed to new replies.