XF 2.0 How to create a new button for full-page reply?


New member
Members on my forum would find it useful to write their replies on a separate page, instead of right below the threads. A bit of google-ing and I found this,


According to that thread, what I need to do, is append a "/reply" to the thread URL. Some searching inside the admin pages led me to the template titled "quick_reply_macros". That template displays the "Preview" and "Post reply" buttons. What I want to do is add a new "Reply on new page" button which would add the "/reply" to the current thread title.

Thing is, I'm stumped on how to do this. :(

I've figured out that I can use

<xf:button href="{{ link('$requestPaths.requestUri', 'reply') }}" class="button--link" icon="preview">Reply on new page</xf:button>

to show my button. Clicking the button will open a new page, but not the full-page reply that I want. Experimentation (and one thread here somewhere) showed me that $requestPaths.requestUri will give me the current thread link. But I can't quite figure out what to write as the href/link.

Help please?

<xf:button href="reply" class="button--link" icon="preview">Reply on new page</xf:button>
You actually would want to use the link builder, but I guess that works aswell.
That does work only for friendly urls turned on. You would need to activate that in the board options, if possible.

The link builder is the function you used above {{link()}}.
<xf:button href="{{ link('threads/reply', $__globals.thread) }}" class="button--link" icon="preview">Reply on new page</xf:button>
Something like this
Top Bottom