Thursday, 24 February 2011

NextGen Gallery - Secure those pictures!

Share |
NextGen Gallery, protect those pictures by preventing drag and drop.


Note that we are modifying the twenty-ten theme's header file to replace the default header image with the NextGen Gallery slideshow.

NextGen Gallery Plugin for wordpress


Ever used NextGen Gallery plugin for wordpress, and found your site visitors just happily copying away at those precious pictures?

It is a great plugin with the watermark feature and more, but what if we just want to deter the casual image thief just that little more?

What I will offer now is the solution to prevent this from happening, not that it is 100% full-proof since nothing in the world is such. But here goes...

Header.php

1. Log in to your wordpress admin panel, and under Appearance, select Editor
2. Select the Header.php file to edit
3. Choose where you want to insert NextGen slideshow.(I suggest searching for "header_image()" and commenting out or removing the whole line)
4. Add this line just after that:
<div onmousedown="return false">
<?php nggSlideshowWidget(1,HEADER_IMAGE_WIDTH,HEADER_IMAGE_HEIGHT); ?>
</div>
5. And while you are at it, you might as well disable right-click too! Follow instructions here.
6. There its done! Users will no longer be able to drag and drop those images to their desktop.

We have just made images harder to steal!

Finally...
It could possibly be a nice feature to add into the plugin for future releases.

Wordpress Version: 3.0.3
Theme: Twenty-ten
NextGen Gallery Version: 1.7.4

No comments:

Post a Comment

Comments will be moderated.
You can always click 'Contact me' link to get in touch directly.