XF 1.1 Where are post links converted to a page number?

Heya Everyone,

I was wondering where a URL like this:
http://forumurl.com/index.php?posts/1173269/

Is converted into this:
http://forumurl.com/index.php?threads/thread-title.83010/page-16#post-1173269

Specifically, I'm looking for which part of the code takes a post ID and finds the page it's supposed to be on.

The reason why is a little tricky, but I'm essentially creating a system where each page in a thread can have a variable amount of actual posts. I can paginate this correctly, but I need to put a little extra logic in the part where those links are converted so links with just a post ID will go to the right page.

Thank you very much for any help! :)
 
Aha, found it!

If anyone else is curious, it's the function

Code:
public function getPostSpecificRedirect(array $post, array $thread,
                $redirectType = XenForo_ControllerResponse_Redirect::SUCCESS
        )

In XenForo/ControllerPublic/Post.php.
 
Back
Top Bottom