MyBB Community Forums

Full Version: Forum icons help
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
So,I messed up.After several tweaks to my templates and after refreshing my forum's index my forum icons(and some other stuff as you'll see) got misplaced for a reason and I can't figure out why.Also,I can't seem to remember which templates I edited so that makes it even harder to find a solution.

Update: Fixed.
(2016-09-19, 11:36 PM)sterg Wrote: [ -> ]Also,I can't seem to remember which templates I edited so that makes it even harder to find a solution.

Go ACP->Templates&Styles->Themes->Export Theme.
Make sure both radio buttons (Include customized items only? and
Include templates in the export as well?) are set to "Yes".
Then click "Export Theme".

Read the returned XML file to see what you changed to get an idea what might have been the mistake.
Here you go:
Your mistake is in forumbit_depth2_forum template, maybe you can figure it out, or try posting that template here.
(2016-09-20, 12:07 AM)Ashley1 Wrote: [ -> ]Your mistake is in forumbit_depth2_forum template, maybe you can figure it out, or try posting that template here.

My default theme has the same forumbit_depth2_forum and it works fine though..
You should have made a new child style to inherit from the theme you downloaded to get instead of the whole theme only the modifications you made.
As you apparently didn't do this, you have few choices:
  • compare/diff your modified theme file against the original one to find what you changed
  • try to find the bug without diff (probably difficult to impossible)
  • start anew from scratch (this time modifying not the original theme but only the inherited theme that you created after installing that custom theme)
I don't think it was a good idea to attach your custom theme unless you don't care about the copyright, you might want to remove it afterwards. Anyway I checked and like i said the problem is in the forumbit_depth2_forum template. You have 6 <td>s there while there's a colspan 5 in the forumbit_depth1 template. Also the <td> for your icons is located at the end of the row, where it should be at the front.

<tr>
<td class="{$bgcolor} responsivehide" align="center" width="1"><span class="forum_status forum_{$lightbulb['folder']} ajax_mark_read" title="{$lightbulb['altonoff']}" id="mark_read_{$forum['fid']}"></span></td>
<td class="{$bgcolor}">
<div class="fbittext"><strong><a href="{$forum_url}">{$forum['name']}</a></strong>{$forum_viewers_text}<span class="responsiveshow fbittooltip">{$lang->forumbit_threads}: {$threads}{$unapproved['unapproved_threads']} {$lang->forumbit_posts}: {$posts}{$unapproved['unapproved_posts']}</span></div>
<div class="smalltext"><span class="ccforumdescription">{$forum['description']}{$modlist}</span>{$subforums}</div>
</td>
<td class="{$bgcolor} responsivehide" align="center" style="white-space: nowrap">{$threads}{$unapproved['unapproved_threads']}</td>
<td class="{$bgcolor} responsivehide" align="center" style="white-space: nowrap">{$posts}{$unapproved['unapproved_posts']}</td>
<td class="{$bgcolor}" align="right" style="white-space: nowrap">{$lastpost}</td>
<td class="{$bgcolor}" align="center" valign="top" width="1"><img src="images/ficons/{$forum['fid']}.png" /></td>

</tr>
(2016-09-20, 12:29 AM)Ashley1 Wrote: [ -> ]I don't think it was a good idea to attach your custom theme unless you don't care about the copyright, you might want to remove it afterwards. Anyway I checked and like i said the problem is in the forumbit_depth2_forum template. You have 6 <td>s there while there's a colspan 5 in the forumbit_depth1 template. Also the <td> for your icons is located at the end of the row, where it should be at the front.

<tr>
<td class="{$bgcolor} responsivehide" align="center" width="1"><span class="forum_status forum_{$lightbulb['folder']} ajax_mark_read" title="{$lightbulb['altonoff']}" id="mark_read_{$forum['fid']}"></span></td>
<td class="{$bgcolor}">
<div class="fbittext"><strong><a href="{$forum_url}">{$forum['name']}</a></strong>{$forum_viewers_text}<span class="responsiveshow fbittooltip">{$lang->forumbit_threads}: {$threads}{$unapproved['unapproved_threads']} {$lang->forumbit_posts}: {$posts}{$unapproved['unapproved_posts']}</span></div>
<div class="smalltext"><span class="ccforumdescription">{$forum['description']}{$modlist}</span>{$subforums}</div>
</td>
<td class="{$bgcolor} responsivehide" align="center" style="white-space: nowrap">{$threads}{$unapproved['unapproved_threads']}</td>
<td class="{$bgcolor} responsivehide" align="center" style="white-space: nowrap">{$posts}{$unapproved['unapproved_posts']}</td>
<td class="{$bgcolor}" align="right" style="white-space: nowrap">{$lastpost}</td>
<td class="{$bgcolor}" align="center" valign="top" width="1"><img src="images/ficons/{$forum['fid']}.png" /></td>

</tr>

I changed colspan5 to colspan6 and added the <td> first but it still shows last..

Also,I reverted to the original and the icons are still there..how is that possible?

Update:The icons are fixed now..
(2016-09-20, 12:45 AM)sterg Wrote: [ -> ]I changed colspan5 to colspan6 and added the <td> first but it still shows last..

Also,I reverted to the original and the icons are still there..how is that possible?

You must have edited in the wrong template set, although i see that you have changed the colspan. 

From what i can see you don't need to change to colspan 6, so try putting it back to 5 and then you fix the problem in forumbit_depth2_forum.

Not sure if you were trying to replace the first <td>, but you can try this:

<tr>
<td class="{$bgcolor}" align="center" valign="top" width="1"><img src="images/ficons/{$forum['fid']}.png" /></td>
<td class="{$bgcolor}">
<div class="fbittext"><strong><a href="{$forum_url}">{$forum['name']}</a></strong>{$forum_viewers_text}<span class="responsiveshow fbittooltip">{$lang->forumbit_threads}: {$threads}{$unapproved['unapproved_threads']} {$lang->forumbit_posts}: {$posts}{$unapproved['unapproved_posts']}</span></div>
<div class="smalltext"><span class="ccforumdescription">{$forum['description']}{$modlist}</span>{$subforums}</div>
</td>
<td class="{$bgcolor} responsivehide" align="center" style="white-space: nowrap">{$threads}{$unapproved['unapproved_threads']}</td>
<td class="{$bgcolor} responsivehide" align="center" style="white-space: nowrap">{$posts}{$unapproved['unapproved_posts']}</td>
<td class="{$bgcolor}" align="right" style="white-space: nowrap">{$lastpost}</td>
</tr>
Now,all that's been left to be fixed is to remove the thread/posts right next to the title..
Pages: 1 2