Infinite scroll repeating first page
-
Hi,
I have got the infinite scroll plugin working (functionality wise) but i am experiencing an weird issue. When you scroll down, the first page displays in infinity scrolls loading, and then it continues.
So it does the following
Normal view – person scrolls down
PAGE 1
Loading infinite scroll:
PAGE 1 [AGAIN]
PAGE 2
etc..Why would that happen?
Here is teh functions.php
function my_theme_infinite_scroll_setup() { add_theme_support( 'infinite-scroll', array( 'type' => 'scroll', 'footer_widgets' => false, 'container' => 'supercontent', 'wrapper' => true, 'render' => false, 'posts_per_page' => false, ) ); } add_action( 'after_setup_theme', 'my_theme_infinite_scroll_setup' );
Here is the index.php file
<div id="supercontent" class="entry-content supercontent"> <?php if (have_posts()) : ?> <?php while (have_posts()) : the_post(); ?> <?php get_template_part( 'content', get_post_format() ); ?> <?php endwhile; ?> <?php endif; ?> </div><!-- .entry-content -->
What am i doing wrong?
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Infinite scroll repeating first page’ is closed to new replies.