MyBB Community Forums

Full Version: Subforum in columns
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I followed the tutorial posted by Yaldaram.
It works in 1.8 too, but there is the additional dot  for each subforum as mentioned in that topic.
The Yaldaram solution to remove those dots, deleting the   is not valid cause in my theme global.css there are not  

Can someone please help?
You can find the item for each subforum in the following template:
Forum Bit Templates > forumbit_depth3

For a columned display of the subforums, you can make the subforum elements float left to a third of the width (three columns) or a fifth of the width (five columns) like that:

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

Style in global.css:
.float_left_30 {
	float: left;
	width: 30%;
}

Doing so will show all subforums in three columns with a third of the width each, breaking at the end of the line with the next three subforums.

It is important to clear the floating elements at the end of all subforums... so add the following clear line after the variable in template forumbit_subforums:
{$sub_forums}
<div class="clear"></div>


As a benefit you can also make this floating subforums responsive at a specific width by changing the class float_left_30 to width:100% or display:block. Then subforum elements will be shown in rows:
@media screen and (max-width: 650px) {
	.float_left_30 {
		display: block;
		width: 100%;
	}
}

[ExiTuS]