WordPress.org

Ready to get started?Download WordPress

Forums

Allow hotlinking for thumbnails (2 posts)

  1. leemon
    Member
    Posted 3 years ago #

    Hi!

    I'm wondering if there's a way to allow hotlinking for thumbnails and ban it for everything else. My thumbnails have the following syntax.

    filename-150x150.jpg

    Thanks in advance

  2. leemon
    Member
    Posted 3 years ago #

    I came up with a solution. Put the following lines in the .htaccess file:

    RewriteCond %{REQUEST_URI} !-150x150\.jpg$
    RewriteRule .*\.(jpg|jpeg)$ - [F,NC]

Topic Closed

This topic has been closed to new replies.

About this Topic