Like this if you want to add a hash
{!! $foo->fragment('post-123')->render() !!}
I 'm building a forum and I have a list of all the sections. And in these sections are threads. In this list of the sections I want to link to the latest post in a thread.
As on this page, if you click on "Updated X minutes ago".
So the link should look like this..
www.example.com/section/thread?page=1#post-123
Right now I can already link to the thread where the latest post is. But I do not know how I can link it to the page.
?page=1
How I can do that?
Thanks in advance! :)
Edit: So in the thread view I already have a pagination. I only want to link the post to the correct page.
@SiiXFX get the number of posts in the thread then divide it by the number of posts per page so you have the last page number.
Please or to participate in this conversation.