diff options
Diffstat (limited to 'themes/default/js')
-rw-r--r-- | themes/default/js/thumbnails.loader.js | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/themes/default/js/thumbnails.loader.js b/themes/default/js/thumbnails.loader.js index e1eba51da..9483caeb6 100644 --- a/themes/default/js/thumbnails.loader.js +++ b/themes/default/js/thumbnails.loader.js @@ -21,9 +21,10 @@ function add_thumbnail_to_queue(img, loop) { }); } -jQuery('img').each(function() { - var img = jQuery(this); - if (typeof img.data('src') != 'undefined') { - add_thumbnail_to_queue(img, 0); - } -});
\ No newline at end of file +function pwg_ajax_thumbnails_loader() { + jQuery('img[data-src]').each(function() { + add_thumbnail_to_queue(jQuery(this), 0); + }); +} + +jQuery(document).ready(pwg_ajax_thumbnails_loader);
\ No newline at end of file |