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

XF 1.2 hiding 3rd level children forums with conditionals

Live Free

Active member
I'm using @Jaxel's subforum listing template edits and trying to hid particular child forums from existing child forums on the index page because they clutter the index and aren't used often enough. I'm getting closer, but I've seemingly run into a wall.

Screen Shot 2013-09-14 at 4.33.05 PM.png

Here I'd like to hide the child forums of Contest Archives, Weekly SSC, WEekly PC.

The original:

<xen:require css="EWRcustom_forum_list.css" />

<xen:if is="{$level} == 2 AND {$renderedChildren}">
<li class="subForumsContainer secondaryContent {xen:if '{$category.node_id}', 'grid_{$category.node_id}'} {xen:if '{$forum.node_id}', 'grid_{$forum.node_id}'}">
    <div class="subForumsGrid">
        <ol class="blockLinksList blockLinksGrid">
        <xen:foreach loop="$renderedChildren" value="$child">
            {xen:raw $child}
What I've managed to do is change the first if statement to this:

<xen:if is="{$level} == 2 AND {$renderedChildren} AND {$forum.node_id} != 62">
Here I'm trying to hide node 62 from the grid. This works if node 62 is a top-level forum. However, if node 62 is a child forum or a child-child forum, this statement doesn't do any good and it displays anyway. (This leads me to believe $forum.node_id isn't applying to child forums for some reason?)

I've tried $forum_node_id and $forum_parent_node_id and can't quite get it. I'm still a newbie with this sort of thing, so if someone could point me in the right direction I'd appreciate it.