Get "Load more button" to chage URL

Posted in: Newspaper
Post count: 4

I’m using Block 11 to list latest posts on my homepage. As a pagination, I’ve chosen the “Load more button”. When I click load more button next x number of posts are shown, but the url is not changed.

I want the load more button to change the url as /page=2, /page=3, /page=4, etc. everytime it’s clicked.

This feature is neccessary because I want users to land on the same loaded part of posts when they hit “Back” button on their browsers.

Post count: 4

I found this code in td_block.php:

case 'load_more':
//if ($this->td_query->found_posts > $limit) {
if ($this->td_query->found_posts - $offset > $limit) {
$buffy .= '<div class="td-load-more-wrap">';
$buffy .= 'block_uid . '" data-td_block_id="' . $this->block_uid . '">' . __td('Load more', TD_THEME_NAME);
$buffy .= '<i class="td-icon-font td-icon-menu-down"></i>';
$buffy .= '
';
$buffy .= '</div>';
}
break;

How do I know what changes to URL it’s doing behind the scenes?
How do I get those changes to show up in URL bar of the browser?

Post count: 23312

Hi Akhmatovich,

Unfortunately, our theme does not have any such an option for it that allows you to do this, sorry! If you want to implement this feature and change the URL to be different for each load pagination, you should implement it yourself through the code because we cannot provide custom services at the moment, sorry! As a hint, you can try using the smart list implementation. If you are not aware of the steps which are needed to take in this case, please consider hiring a freelancer/developer to help you because we cannot provide custom services at the moment, sorry!

Thanks for your understanding!

Viewing 3 posts - 1 through 3 (of 3 total)
The forum ‘Newspaper’ is closed to new topics and replies.