Advertisement
Guest User

Untitled

a guest
Jul 29th, 2014
190
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.65 KB | None | 0 0
  1. var passObject = {};
  2.  
  3. $.ajax({
  4. url:"<?php bloginfo('template_directory'); ?>/inc/galleries.php",
  5. type: 'POST',
  6. data: passObject,
  7. success: function(resp) {
  8.  
  9. $('#photos').append(resp);
  10.  
  11. }
  12. });
  13.  
  14. <div class="photos">
  15. <h1>Photo Gallery</h1>
  16. <?php if( have_rows('gallery') ): ?>
  17.  
  18. <?php while( have_rows('gallery') ): the_row();
  19.  
  20. // vars
  21. $photo = get_sub_field('photos');
  22.  
  23. ?>
  24. <div class="image"><img src="<?php echo $photo['sizes']['gallery-thumb']; ?>" alt="<?php echo $photo['alt']; ?>" /></div>
  25. <?php endwhile; ?>
  26.  
  27. <?php endif; ?>
  28. </div>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement