WordPress.org

Ready to get started?Download WordPress

Forums

[Plugin: NextGEN Gallery] How to prevent image hotlinking? (4 posts)

  1. teknoledge
    Member
    Posted 5 years ago #

    Is there a way not to use JS effects for opening images but instead to get image opened via template file so every image is like a single post?

    Also to use permalinks to prevent hotlinking, e.g.

    gallery-name/image-name

    Thanks in advance,
    Milos

  2. Alex Rabe
    Member
    Posted 5 years ago #

    have you tried the Imagebrowser feature (see options)

    or switch to the WP Core gallery... (Which comes without the effect)

  3. Williwaw
    Member
    Posted 5 years ago #

    You can put this into your .htaccess to prevent the hotlinking

    RewriteEngine on
    RewriteCond %{HTTP_REFERER} !^$
    RewriteCond %{HTTP_REFERER} !^http://(www\.)?YourDomain.com/.*$ [NC]
    RewriteRule \.(gif|png|jpg)$ - [F]
  4. teknoledge
    Member
    Posted 5 years ago #

    @alexrabe
    Ah, exactly what I was looking for. :)

    @Williwaw
    I was thinking more about permalinks for images e.g.

    wp-content/gallery/whatever/image-file-name-jpg/

    instead of:

    wp-content/gallery/whatever/image file name.jpg

    Also it would be good to add replacement of spaces (' ') with hyphens for uploaded images in the feature versions of NGG, I'm sure it's not a big job.

    Cheers! :)

Topic Closed

This topic has been closed to new replies.

About this Topic