• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

XF 1.2 Can I access the name(slug) of a forum while in that forum?

Razasharp

Well-known member
#1
Is there any way I can access the name of a forum/node when on the forum view page or while in one of its threads?

So if I was viewing this thread, which is inside the XenForo Questions and Support' forum, I would like to get the last part of the url, i.e 'xenforo-questions-and-support.25/'

Or is it possible just to get the name, then call a paramaterize type method on it to churn out a URL-friendly string?

I don't need the full url, just the last bit, because I need to link off-site to a section elsewhere.
 

Brogan

XenForo moderator
Staff member
#2
Try using $forum.node_name.

FYI, if you add {xen:helper dump, $forum} to the forum_view template, a full list of params will be output.
 

Razasharp

Well-known member
#3
Awesome, thanks!

Btw, is there a dev mode or other setting which automatically gives info such as which variables are accessible, or which templates are being used per page?