MyBB Community Forums
Need to adjust subforums layout - Printable Version

+- MyBB Community Forums (https://community.mybb.com)
+-- Forum: 1.8 Support (https://community.mybb.com/forum-175.html)
+--- Forum: General Support (https://community.mybb.com/forum-176.html)
+--- Thread: Need to adjust subforums layout (/thread-164737.html)



Need to adjust subforums layout - DotaInternational - 2014-12-26

Hello I want a small editing in my sub forums layout.
So currently sub forums show horizontally as they show on all MyBB forums as shown below.

[attachment=33373]

I want to show them vertically like this. I made this image by editing the source code of page, but I can not find anything in forumbit_subforums to edit it as there is only one code

{$subforums}

[attachment=33374]

So how can I show subforums vertically instead of horizontal view ?

Regards.


RE: Need to adjust subforums layout - mmadhankumar - 2014-12-27

ACP >> Templates >> Your Theme's Template >> Forum Bit Templates >> forumbit_depth3 >> Replace the code with

<br />{$statusicon}<a href="{$forum_url}" title="{$forum_viewers_text_plain}">{$forum['name']}</a>



RE: Need to adjust subforums layout - singleboy - 2014-12-27

I want to make 2 vertical columns of subforums. Please guide me how do I show them in columns?


RE: Need to adjust subforums layout - mmadhankumar - 2014-12-27

(2014-12-27, 11:40 AM)singleboy Wrote: I want to make 2 vertical columns of subforums. Please guide me how do I show them in columns?

to make two columns, first goto

ACP >> Templates >> Your Theme's Template >> Forum Bit Templates >> forumbit_depth3 >> Replace the content with

<li>{$statusicon}<a href="{$forum_url}" title="{$forum_viewers_text_plain}">{$forum['name']}</a></li>


Step 2: ACP >> Templates >> Your Theme's Template >> Forum Bit Templates >> forumbit_subforums >> Replace the content with

<br />{$lang->subforums}<br /><ul class="sub_forums">{$sub_forums}</ul>


Step 3: Add this to global.css

.sub_forums {
list-style: none; 
margin: 0; 
padding: 0;
}

.sub_forums li {
width: 50%; 
float: left;
}

Save everything open your forums and do a hard refresh (Ctrl+F5) if you dont see the changes....

TIP: the "width: 50%" gives us the two column layout, changing that to 33% will give 3 columns, 100% will give single column and so on... Big Grin


RE: Need to adjust subforums layout - singleboy - 2014-12-27

I have made the above changes but it is still showing one column layout.


RE: Need to adjust subforums layout - mmadhankumar - 2014-12-27

(2014-12-27, 04:12 PM)singleboy Wrote: I have made the above changes but it is still showing one column layout.

oops sorry, typo Toungue I forgot to close the li tag in forumbit_depth3 template.. please check the above post again and change it accordingly...


RE: Need to adjust subforums layout - singleboy - 2014-12-27

please guide me again, how do I close the li tag?

Thanks it is done.