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

XF 1.4 Different style/theme/logo per subforum

#1
Hello,

Is it possible to make xenforo use different logo, style, background, different set of themes per subforum?
If yes, how could I achieve that? Any tips/ideas are highly welcome.

Thanks in advance.

Regards,
Furai
 

Brogan

XenForo moderator
Staff member
#2
There is the option to set the style per node:
upload_2015-5-5_9-38-22.png

Be aware though that having tens of styles will result in slower rebuild times.
 

EQnoble

Well-known member
#3
Hello,

Is it possible to make xenforo use different logo, style, background, different set of themes per subforum?
If yes, how could I achieve that? Any tips/ideas are highly welcome.

Thanks in advance.

Regards,
Furai
You could do that with different styles and forcing them by node as in the image above or you could use conditionals and template edits/mods targeting node ids if you don't want to increase loads, AKA custom development.
 
#4
I'd prefer crafting something custom. I've considered in past forcing themes by node but then I'd limit my users to only one theme.

EDIT:
Where to start?
 
Last edited:

Russ

Well-known member
#6
What do you mean by "crafting something custom", what exactly would you want to do, at least a general idea so we can point you in the right direction :)
 
#7
In the OP I've said what I want to get done. I don't know what can I use to do that.

Let's say that I have subforum which I want to look like full forums but with different logo and different background for every theme/different pool of themes to choose from.
I know that I should modify templates for nodes in order to make subforums look like full forums. Haven't figured out that yet as I don't understand that whole XF template language.
 

Brogan

XenForo moderator
Staff member
#8
You would need to edit the top level templates and use conditional statements to achieve background, logo, header changes, etc.
 
Last edited:
#10
So, I've started looking through node_forum_level_2 template and I found this:
Code:
    <xen:if is="{$renderedChildren} AND {$level} == 2 AND 1==2">
       <ol class="subForumList">
       <xen:foreach loop="$renderedChildren" value="$child">
         {xen:raw $child}
       </xen:foreach>
       </ol>
     </xen:if>
That if clause makes completely no sense. Can someone enlighten me? I mean the last part. How the hell 1 can equal 2? :)
 

Brogan

XenForo moderator
Staff member
#11
That sounds like something you have added yourself or from a custom style.

I'm not seeing that in a default template for 1.4 or 1.5.
 

EQnoble

Well-known member
#12
So, I've started looking through node_forum_level_2 template and I found this:
Code:
    <xen:if is="{$renderedChildren} AND {$level} == 2 AND 1==2">
       <ol class="subForumList">
       <xen:foreach loop="$renderedChildren" value="$child">
         {xen:raw $child}
       </xen:foreach>
       </ol>
     </xen:if>
That if clause makes completely no sense. Can someone enlighten me? I mean the last part. How the hell 1 can equal 2? :)
Code:
        <xen:if is="{$renderedChildren} AND {$level} == 2 AND !@nodeListSubForumPopup">
            <ol class="subForumList">
            <xen:foreach loop="$renderedChildren" value="$child">
                {xen:raw $child}
            </xen:foreach>
            </ol>
        </xen:if>
I believe that is the default code that should be in place of the block of code you posted.