• I’m developing my own theme and added Infinite Scroll plugin for loading my custom post type “reference”. Pagination is ok, if I click on “Older” can see loading. But result is “no additional posts” (and I have three more posts like that). I think it’s maybe because I have wrong selection in Settings. Here is what I have:

    Content selector: .reference

    Navigation selector: #nav

    Next selector: #nav .older a

    Item selector: .ref

    Behavior: Manual Trigger

    for this code:

    <div class="container center reference">
      <?php
        $temp = $wp_query;
        $wp_query = null;
        $wp_query = new WP_Query();
        $wp_query->query('showposts=3&post_type=reference'.'&paged='.$paged); 
    
        while ($wp_query->have_posts()) : $wp_query->the_post();
      ?>
    
    <div class="ref hidden" style="float:left; margin: 10px">
      <a>" rel="lightbox">
        <?php the_post_thumbnail( 'medium' );  ?>
      </a>
      <div style="display: none;">
        <div id="reference-<?php echo the_ID(); ?>">
          <?php the_title();  ?> <?php echo the_excerpt();?>
    
    <?php the_post_thumbnail( 'medium' );  ?>
        </div>
      </div>
    </div>
    <?php endwhile; ?>
    
    <nav id="nav">
      <div class="newer"><?php previous_posts_link('« Newer') ?></div>
      <div class="older"><?php next_posts_link('Older »') ?></div>
    </nav>
    </div>

    I tried change it, but still nothing works. My page is http://www.primawork.cz (it’s at the end of page with heading “Naše reference”) and pagination without Infinite Scroll works well. Is it really just about wrong selector or have anyone some other experience?

    https://wordpress.org/plugins/infinite-scroll/

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter CyberPanda

    (@tenshinhikaru)

    Okay, I tried something more, but nothing helped. I also tried change permalinks to default. Debbug console show this:

    Uncaught Error: Syntax error, unrecognized expression: http://primawork.cz/?paged=2

    But link ..?paged=2 is okay.

    (before it was Uncaught Error: Syntax error, unre….: http://primawork.cz/page/2 and this link worked too)

    Anyone?

    Hi,

    I installed infinite scrolling plugin but its not working.
    http://www.filmcutz.com/

    once check my configuration what i was did.
    Content Selector .content
    Navigation Selector #nav-header.nav-container
    Next Selector #nav-header.nav-container a:first
    Item Selector .post

    tell me where i was mistake in settings

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘selectors doesn't work, what is wrong?’ is closed to new replies.