Modify URL of blog_page_link function

Hi guys,

does anybody know how to modify the output URL of the blog_page_link function; to be precise, adding an URL extension?

My blog listing section is not at the top of the website but it obviously jumps back to the top when I, for instance, move on to the next page, last page, etc.

Since this function is used in the href attribute, I figured that I could jump to the desired section by adding the div id in the URL.

Would appreciate any ideas. :slightly_smiling_face:

Cheers,

-Henry

Hi @henryd1,

I see no reason why adding the ID as a hash in the href attribute wouldn’t work. That’s what I’d suggest doing. So you’d have something like:

<a href="{{ blog_page_link(next_page_num) }}#blog-listing-section">Next</a>

If that’s not working, could you link me to your blog? I’m sure we can get it figured out.

Hi @lscanlan,

and many thanks for your answer, your help is very much appreciated!

You’re absolutely right.

Thanks to your response I was able to find the culprit and I did a beginner’s mistake, I have to admit… forgot to add the id attribute to the blog listingmark up itself (silly me).

Many thanks again for your help, Leland!

Cheers,