[Plugin: NextGEN Gallery] Hack on nextgen gallery
-
Hello Alex: see at this url
http://www.laserscan.it/test/lavora-con-noi/As you see i have added a simple jquery script for sho w a loading image, but i have made 3 change at the core
1) add the class of the span in the nggallery.css
2) insert into gallery.php (view) the php code for create a span with the thumb options set into the adminline 40 to….
<div id="ngg-image-<?php echo $image->pid ?>" class="ngg-gallery-thumbnail-box" <?php echo $image->style ?> > <div class="ngg-gallery-thumbnail" > <a href="<?php echo $image->imageURL ?>" title="<?php echo $image->description ?>" <?php echo $image->thumbcode ?> > <?php if ( !$image->hidden ) { ?> <span class="image_block_archive image_block_archive-<?php echo $image->pid ?> img_loading" style="width:<?php echo $thumbwidth?>px;height:<?php echo $thumbheight?>px"> <script type="text/javascript"> <!-- jQuery(function () { var img = new Image(); jQuery(img).load(function () { jQuery(this).hide(); jQuery(this).fadeIn(1200); jQuery('.image_block_archive-<?php echo $image->pid ?>').removeClass('img_loading').append(this); }).error(function () { // notify the user that the image could not be loaded }).attr( "src", '<?php echo $image->thumbnailURL ?>' ); jQuery(img).attr('alt','<?php echo $image->alttext ?>'); }); //--> </script> </span> <?php } ?> </a> </div> </div>3) for use the options i have edit the line 380 og nggfunctions.php edited as
// create the output $out = nggGallery::capture ( $filename, array ('gallery' => $gallery, 'images' => $picturelist, 'pagination' => $navigation, 'current' => $current_pid, 'next' => $next, 'prev' => $prev,'width'=>$thumbwidth,'height'=>$thumbheight) );If you think this feature useful, may be witha option, and you want the code without edit, sens me a email to info @ andreabersi dot com
Thank you
The topic ‘[Plugin: NextGEN Gallery] Hack on nextgen gallery’ is closed to new replies.