Guest User

Untitled

a guest
Nov 23rd, 2017
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.65 KB | None | 0 0
  1. <div class="gallery">
  2. <h3><span>Gallery</span></h3>
  3. <div id="gallery" class="content">
  4. <div id="controls" class="controls"></div>
  5. <div class="slideshow-container">
  6. <div id="loading" class="loader"></div>
  7. <div id="slideshow" class="slideshow"></div>
  8. </div>
  9. </div>
  10. <div id="thumbs" class="navigation">
  11. <ul class="thumbs noscript">
  12. <?php $hot_news = new WP_query(); $hot_news->query('showposts=6&cat='.$mytheme['gal_cat']); ?>
  13. <?php while ($hot_news->have_posts()) : $hot_news->the_post(); ?>
  14. <li>
  15. <a class="thumb" href="<?php img_gallery(297,190) ?>" title="<?php the_title() ?>">
  16. <?php img(90,70) ?>
  17. </a>
  18.  
  19. </li>
  20. <?php endwhile; ?>
  21. </ul>
  22. </div>
  23. <script type="text/javascript">
  24. jQuery(document).ready(function($) {
  25. // We only want these styles applied when javascript is enabled
  26. $('div.navigation').css({'width' : '320px', 'float' : 'right'});
  27. $('div.content').css('display', 'block');
  28.  
  29. // Initially set opacity on thumbs and add
  30. // additional styling for hover effect on thumbs
  31. var onMouseOutOpacity = 0.67;
  32. $('#thumbs ul.thumbs li').opacityrollover({
  33. mouseOutOpacity: onMouseOutOpacity,
  34. mouseOverOpacity: 1.0,
  35. fadeSpeed: 'fast',
  36. exemptionSelector: '.selected'
  37. });
  38.  
  39. // Initialize Advanced Galleriffic Gallery
  40. var gallery = $('#thumbs').galleriffic({
  41. delay: 2500,
  42. numThumbs: 15,
  43. preloadAhead: 10,
  44. enableTopPager: false,
  45. enableBottomPager: false,
  46. maxPagesToShow: 1,
  47. imageContainerSel: '#slideshow',
  48. renderSSControls: false,
  49. renderNavControls: false,
  50. enableHistory: false,
  51. autoStart: false,
  52. syncTransitions: true,
  53. defaultTransitionDuration: 900,
  54. onSlideChange: function(prevIndex, nextIndex) {
  55. // 'this' refers to the gallery, which is an extension of $('#thumbs')
  56. this.find('ul.thumbs').children()
  57. .eq(prevIndex).fadeTo('fast', onMouseOutOpacity).end()
  58. .eq(nextIndex).fadeTo('fast', 1.0);
  59. },
  60. onPageTransitionOut: function(callback) {
  61. this.fadeTo('fast', 0.0, callback);
  62. },
  63. onPageTransitionIn: function() {
  64. this.fadeTo('fast', 1.0);
  65. }
  66. });
  67. });
  68. </script>
  69. </div>
Add Comment
Please, Sign In to add comment