Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Darren Cooney

    (@dcooney)

    Not sure what you mean… are you saying the button never disables?

    Thread Starter raybeam

    (@raybeam)

    Yes, that’s what I’m saying. I have 9 posts and when they all load the button is still there.

    Plugin Author Darren Cooney

    (@dcooney)

    If you load 3 posts at a time and you have 9 posts it won’t disable until you press the load button 1 more time.

    Thread Starter raybeam

    (@raybeam)

    No, I can click the button as may times as I want after the final post loaded and it remains there. You can see the demo here: https://www.charlesalandesign.com/chaostackle/products/

    Plugin Author Darren Cooney

    (@dcooney)

    Sounds like an issue with your repeater template.
    Can you post that?

    Thread Starter raybeam

    (@raybeam)

    Is it because I have the modal in there?

    <li class="ct-product">
    			<?php the_post_thumbnail(); ?>
    			<div class="ct-product-text">
    				<div class="inner-product-text">
    				<h4><?php the_title(); ?></h4>
    				<?php
    				$attributes = get_the_terms( $product->id, 'pa_color');
    				if ( $attributes && ! is_wp_error( $attributes ) ) :
    				foreach ( $attributes as $attribute ) {
    				echo "<p>" . $attribute->name . "</p>";
    				}
    				endif; ?>
    				<div class="ct-product-buttons">
    					<span class="ct-product-button expand-prod"><a data-toggle="modal" data-target="#<?php echo get_the_ID(); ?>" href="#"></a></span>
    					<span class="ct-product-button share-prod">
    						<a href="#"></a>
    						<div class="social-sharing-icons">
    							<?php echo pixelers_social_links(); ?>
    						</div>
    					</span>
    
    				</div>
    				</div>
    			</div>
    		</li>
    <div class="modal fade" id="<?php echo get_the_ID(); ?>" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
    	  <div class="modal-dialog" role="document">
    	    <div class="modal-content">
    	      <div class="modal-header">
    	        <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
    	        <h4 class="modal-title" id="myModalLabel"><?php the_title(); ?></h4>
    	        <?php
    			$attributes = get_the_terms( $product->id, 'pa_color');
    			if ( $attributes && ! is_wp_error( $attributes ) ) :
    			foreach ( $attributes as $attribute ) {
    			echo "<p class=\"modal-sub-title\">" . $attribute->name . "</p>";
    			}
    			endif; ?>
    	      </div>
    	      <div class="modal-body">
    		      <div class="row">
    			      <div class="col-md-6"><?php the_post_thumbnail(); ?></div>
    			      <div class="col-md-6"><?php the_content(); ?></div>
    		      </div>
    	      </div>
    	      <div class="modal-footer">
    	        <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
    	      </div>
    	    </div>
    	  </div>
    	</div>
    Plugin Author Darren Cooney

    (@dcooney)

    Yes. Your repeater template should be fully wrapped in an html element.

    Move the modal inside the LI

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Destroy load more after loading max number of posts’ is closed to new replies.