Advertisement
Guest User

gallery.php

a guest
Feb 22nd, 2014
166
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.17 KB | None | 0 0
  1. <?php
  2. /**
  3. Template Page for the gallery overview
  4.  
  5. Follow variables are useable :
  6.  
  7. $gallery : Contain all about the gallery
  8. $images : Contain all images, path, title
  9. $pagination : Contain the pagination content
  10.  
  11. You can check the content when you insert the tag <?php var_dump($variable) ?>
  12. If you would like to show the timestamp of the image ,you can use <?php echo $exif['created_timestamp'] ?>
  13. **/
  14. ?>
  15. <?php if (!defined ('ABSPATH')) die ('No direct access allowed'); ?><?php if (!empty ($gallery)) : ?>
  16.  
  17. <div class="ngg-galleryoverview" id="<?php echo $gallery->anchor ?>">
  18.  
  19. <?php if ($gallery->show_slideshow) { ?>
  20. <!-- Slideshow link -->
  21. <div class="slideshowlink">
  22. slideshow_link) ?>">
  23. <?php echo $gallery->slideshow_link_text ?>
  24.  
  25. </div>
  26. <?php } ?>
  27.  
  28. <?php if ($gallery->show_piclens) { ?>
  29. <!-- Piclense link -->
  30. <div class="piclenselink">
  31. piclens_link) ?>">
  32. <?php _e('[View with PicLens]','nggallery'); ?>
  33.  
  34. </div>
  35. <?php } ?>
  36.  
  37. <!-- Pagination -->
  38. <?php echo $pagination ?>
  39.  
  40. <!-- Thumbnails -->
  41. <?php $i = 0; ?>
  42. <?php foreach ( $images as $image ) : ?>
  43.  
  44. <div id="ngg-image-<?php echo $image->pid ?>" class="ngg-gallery-thumbnail-box" <?php echo $image->style ?> >
  45. <div class="ngg-gallery-thumbnail" >
  46. imageURL) ?>"
  47. title="<?php echo esc_attr($image->description) ?>"
  48. data-src="<?php echo nextgen_esc_url($image->imageURL); ?>"
  49. data-thumbnail="<?php echo nextgen_esc_url($image->thumbnailURL); ?>"
  50. data-image-id="<?php echo esc_attr($image->pid); ?>"
  51. data-title="<?php echo esc_attr($image->alttext); ?>"
  52. data-description="<?php echo esc_attr($image->description); ?>"
  53. <?php echo $image->thumbcode ?> >
  54. <?php if ( !$image->hidden ) { ?>
  55. <img title="<?php echo esc_attr($image->alttext) ?>" alt="<?php echo esc_attr($image->alttext) ?>" src="<?php echo nextgen_esc_url($image->thumbnailURL) ?>" <?php echo $image->size ?> />
  56. <?php } ?>
  57.  
  58. </div>
  59. </div>
  60.  
  61. <?php if ( $image->hidden ) continue; ?>
  62. <?php if ($gallery->columns > 0): ?>
  63. <?php if ((($i + 1) % $gallery->columns) == 0 ): ?>
  64. <br style="clear: both" />
  65. <?php endif; ?>
  66. <?php endif; ?>
  67. <?php $i++; ?>
  68.  
  69. <?php endforeach; ?>
  70.  
  71. <!-- Pagination -->
  72. <?php echo $pagination ?>
  73.  
  74. </div>
  75.  
  76. <?php endif; ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement