If you need the code available in the PAGE_CONTAINER template (presumably because the links are going to be displayed outside the thread and forum pages?) then add this to the thread_view template:
That returns a /threads/thread-title.1/page-2 result, what I'm seeking is a template variable that only returns the base thread url in multi-page threads.
Ok, I gave it a try and the result of using that custom string is:
Code:
https://www.forum.com/threads/.
I'm guessing it's because $thread.title and $thread.thread_id need __globals or context or contentKey etc in order to function in the PAGE_CONTAINER template?
The result it produces on page 2 with the thread title this is a test is:
Code:
https://www.forum.com/threads/this+is+a+test.1/
So we're close to what it should be, which is: https://www.forum.com/threads/this-is-a-test.1/
For some reason it's adding + symbols between the words instead of native -'s is the remaining issue.
There's likely an easier way to achieve what I'm trying to do, which is simply to make multi-page thread titles link to the first page of the topic for a specific Usergroup who requested it.
If you need the code available in the PAGE_CONTAINER template (presumably because the links are going to be displayed outside the thread and forum pages?) then add this to the thread_view template: