Forums › Forums › Search & Filter Pro › Infinite scrolling & results per page not working on Custom Post Type Archive
Tagged: infinitescrolling, results
- This topic has 14 replies, 2 voices, and was last updated 5 years, 6 months ago by Trevor.
-
Anonymous(Private) April 30, 2019 at 4:40 pm #209709
Hi,
I have a search form set which targets a custom post type and loads the results in the custom post type archive. The search is working as normal however, the infinite scrolling doesn’t seem to work and when I change the results per page it doesn’t change on the results page.
The custom post type archive is using the standard loop like so:
Can you help please?
<div class="entry-content"> <div class="tender-main-wrapper"> <div id="searchtenders"> <?php echo do_shortcode('[searchandfilter id="3059"]'); ?> </div> <div class="tender-opportunity-panel"> <?php // Start the loop. $count = 1; while ( have_posts() ) : the_post(); echo '<div class="'.$post->ID.' tender-oppor">'; echo '<div class="tender-desc">'; echo '<h2>'.get_field('opportunity').'</h2>'; echo '<p class="lead">' .get_field('funding_organisation').'</p>'; echo '<p><strong>Amount available:</strong> ' .get_field('amount_available').'</p>'; echo '<p><strong>Geographical Coverage:</strong> ' .get_field('geographical_').'</p>'; echo '<p><strong>Contract Duration:</strong> ' .get_field('contract_duration').'</p>'; echo '<p><strong>Deadline:</strong> ' .get_field('deadline').'</p>'; echo '<p><strong>Other notes:</strong> ' .get_field('other_notes').'</p>'; echo '<a class="btn readmore-link" target="_blank" href="' .get_field('hyperlink').'">Read more</a>'; echo '</div>'; echo '<div class="tender-cta">'; echo ' <a class="btn btn-primary" target="_blank" href="'.site_url().'/contact-a-bid-writer/?ref='.get_the_title().'">Contact a Bid Writer</a>'; echo '</div>'; echo '</div>'; // End the loop. $count++; endwhile; ?> </div> </div>
-
AuthorPosts