• Resolved cobra65

    (@cobra65)


    How can I replace Neve ‘blog-archive’ pagination with echo do_shortcode(‘[ajax_load_more …]’) ?

    There are so many hooks, which is great, but I can’t figure this one out.

    Thanks much.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hi @cobra65!

    If you’d like to enable infinite scroll on the blog page, this option is already integrated in the theme, there is no need to implement it with custom code. You can go to Customizer -> Layout -> Blog/Archive, expand “Ordering and Content” and choose “Infinite Scroll” from the dropdown under “Post Pagination” – screenshot.

    Any PHP code that you want to add can be placed at the end of the functions.php file of the child theme. We always recommend to firstly create a child theme and then make any modifications of the code there.

    Have a nice day!

    Thread Starter cobra65

    (@cobra65)

    I don’t understand why you suggested infinite scrolling when that is not what I asked about. I am capable of asking what I really wanted to know.

    There is a propensity of support people on the internet who think they can just correct a poster’s question into what they want it to be… and that has to stop.

    I found the answer myself, for anyone who also needs it:

    function my_pagination () {
    echo do_shortcode(‘[ajax_load_more …]’);
    }
    remove_all_actions(‘neve_do_pagination’);
    add_action(‘neve_do_pagination’, ‘my_pagination’);`

    Hi @cobra65,

    I’m sorry my suggestion wasn’t what you expected. It wasn’t my intention to correct your question, I recommended the infinite scroll feature included in the theme because it offers the same functionality as the one I understood you wanted to achieve, in a simpler way, without the need to add custom code. I’m glad you found a solution that suits your needs in the meantime!

    Kind regards!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘How can I replace Neve ‘blog-archive’ pagination’ is closed to new replies.