Skip to content

Instantly share code, notes, and snippets.

@toutpt
Created December 20, 2013 14:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save toutpt/8055535 to your computer and use it in GitHub Desktop.
Save toutpt/8055535 to your computer and use it in GitHub Desktop.
open all img in a plone site using overlay
var openimginoverlay = function(){
$('img[src$="image_tile"],img[src$="image_thumb"],img[src$="image_mini"],img[src$="image_preview"]')
.each(function(){
var $this = $(this);
if (!$this.parent().is('a')){
$this.prepOverlay({
subtype: 'image',
urlmatch: '/image_.+$',
urlreplace: '',
});
}
});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment