Alex

Forum Replies Created

  • Author
    Posts
  • July 12, 2016 at 11:04 pm #6771

    Hey Rolf, i have changes the auto gallery and sections but now it just shows the lightbox and not the gallery.

    July 12, 2016 at 4:39 am #6769

    Hey Rolf, thank you so much again for your help. It works great. the pictures show up when i add them to the post as a gallery but the images are attachments to the post and they dont show in the gallery. Is it possible or is there a way to add the attachments from a imagepost to the fancybox? Thanks

    July 11, 2016 at 11:07 pm #6763

    yes i am using the Uploader – Advanced Media Sharing Theme. Also thanks for the tips about the child theme =). The theme supports a child theme and that is where i am making my changes. I have added your code above and it works perfectly! When i click on the thumbnail i get the same picture full sized in fancybox. Please help me with getting the post content in a hidden div.

    July 11, 2016 at 4:11 pm #6754

    hi Rolf,

    Thank you for your quick reply. I am using the uploader theme on wordpress. I am new to wordpress so i dont have any experience with the template files but from browsing around i believe this is the code it has for the thumbnail posts that i need help modifying.

    while ( have_posts() ) : the_post(); ?>
    
    <?php
    $post_id = get_the_ID();
    
    $masonry_class = ( $is_masonry ) ? 'mason-item' : 'grid-item'; ?>
    
    <li <?php post_class( $masonry_class );?> data-media_id="<?php echo $post_id;?>">
    	<div class="thumbnail">
    
    	<?php if ( has_post_thumbnail() ):?>
    		<figure class="image">
    			<?php
    			$thumb = ( isset( $settings['thumb_size'] ) ) ? $settings['thumb_size'] : 'large';
    
    			$attachment_id = get_post_thumbnail_id();
    			$attachment = wp_get_attachment_image_src( $attachment_id, $thumb );?>
          
           <a href="<?php echo esc_url( get_permalink() );?>">
    				<img src="<?php echo esc_url( $attachment[0] );?>" alt="<?php echo esc_attr( get_the_title() ); ?>" />
    			</a>
    
    <?php endwhile;?>