• Resolved confused

    (@nicole2010)


    Thanks for a great plugin.
    I have enabled hotlink protection but my images can still be hotlinked. They are still showing on the sites that are hotlinking and on a test site that I used to check.
    The URL is: creativecertificates.com

Viewing 9 replies - 1 through 9 (of 9 total)
  • Plugin Contributor mbrsolution

    (@mbrsolution)

    Hi, can you check your .htaccess file to make sure you see an entry similar to the following entry. If you don’t then you know this feature is not currently working in your site.

    # BEGIN All In One WP Security
    #AIOWPS_PREVENT_IMAGE_HOTLINKS_START
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteCond %{HTTP_REFERER} !^$
    RewriteCond %{REQUEST_FILENAME} -f
    RewriteCond %{REQUEST_FILENAME} \.(gif|jpe?g?|png)$ [NC]
    RewriteCond %{HTTP_REFERER} !^https://localhost/wp442 [NC]
    RewriteRule \.(gif|jpe?g?|png)$ – [F,NC,L]
    </IfModule>
    #AIOWPS_PREVENT_IMAGE_HOTLINKS_END
    # END All In One WP Security

    Regards

    Thread Starter confused

    (@nicole2010)

    Thanks for the response.

    This code appears on my .htaccess.

    I have also deactivated all plugins (besides All In One WP Security) to see if it is a plugin causing the problem but hotlinking is still allowed even when all plugins are deactivated.

    What else can cause the code not to work?

    Plugin Contributor mbrsolution

    (@mbrsolution)

    Hi, try to test one of WordPress default themes like Twenty Seventeen?

    What are your server specs? What PHP version are you running in your server?

    Thread Starter confused

    (@nicole2010)

    I tried two default themes and it didn’t help (I don’t have Twenty Seventeen but I tried Twenty Fourteen and Twenty Fifteen)

    Running PHP version: 7.1.21

    Webserver: nginx/1.15.2

    Plugin Contributor mbrsolution

    (@mbrsolution)

    Hi, thank you for the information. As far as I know nginx does not use .htaccess file. Can you speak to your host to verify and make sure it is an nginx server and not Apache?

    Regards

    Thread Starter confused

    (@nicole2010)

    I used to be on Apache and moved to nginx a few months ago. It could be that the .htaccess is from the old server and it is not active anymore.

    Plugin Contributor mbrsolution

    (@mbrsolution)

    Hi, that explains everything. Nginx does not support .htaccess file. If you want to use this feature, you will have to find what is the nginx alternative.

    Kind regards

    Thread Starter confused

    (@nicole2010)

    OK. Thanks so much for your help.
    Do the rest of the features on your plugin work with Nginx?

    Plugin Contributor mbrsolution

    (@mbrsolution)

    Hi, all the features that don’t write to the .htaccess file work with nginx servers.

    Let me know if you need more information or help.

    Kind regards

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Hotlink protection not working’ is closed to new replies.