Widok działów jak w ZetaBoards

Szukam  Założony przez  MazuLuka.

wersja skryptu MyBB: 1604
adres forum: Grafifor.pl
na czym polega problem (screen, opis, komunikaty, nazwa stylu/theme/szablonu):

Witam,
Przeglądając internet trafiłem na to forum:
http://if.invisionfree.com/index/

Spodobały mi się statystyki działów:
   

Dlatego postanowiłem wdrożyć je w MyBB, ale nie wiem dlaczego mimo, iż struktura tabel jest identyczna jak w ZetaBoards, to forum się rozwala.

Znajomy doszedł do tego, że jako tako to wygląda:
   
Jednak mimo wszystko pragnąłbym, aby wyglądały one tak:
   

Teraz proszę mój szablon forumbit_depth2_cat:
<tr>
<td class="{$bgcolor}" align="center" valign="top" width="1"><img src="{$theme['imgdir']}/{$lightbulb['folder']}.gif" alt="{$lightbulb['altonoff']}" title="{$lightbulb['altonoff']}" class="ajax_mark_read" id="mark_read_{$forum['fid']}" /></td>
<td class="{$bgcolor}" valign="top">
<strong><a href="{$forum_url}">{$forum['name']}</a></strong>{$forum_viewers_text}<div class="smalltext">{$forum['description']}{$modlist}{$subforums}</div>
</td>

<td class="{$bgcolor}" valign="top">
<table cellpadding="0" cellspacing="0" width="100%">
<tr>
<td class="{$bgcolor}" valign="top" align="right" style="white-space: nowrap" colspan="2">{$lastpost}</td>
</tr>
<tr>
<td class="{$bgcolor}" valign="top" align="center" width="50%" style="white-space: nowrap">Postów: {$posts}{$unapproved['unapproved_posts']}</td>
<td class="{$bgcolor}" valign="top" align="center" width="50%" style="white-space: nowrap">Wątków: {$threads}{$unapproved['unapproved_threads']}</td>
</tr>
</table>
</td>

</tr>

Gdy usunę znaczniki <table> forum się rozjeżdża...
Liczę na waszą pomoc. ;)
Adrian napisał 31.07.2011, 14:19:
Poprawiłem nazwę wątku.
Te tabelki... trochę się nagimnastykowałem, ale coś wyszło. ;)

Preview:
   

forumbit_depth2_cat i forumbit_depth2_forum
<tr>
<td rowspan="2" class="{$bgcolor}" align="center" valign="top" width="1"><img src="{$theme['imgdir']}/{$lightbulb['folder']}.gif" alt="{$lightbulb['altonoff']}" title="{$lightbulb['altonoff']}" class="ajax_mark_read" id="mark_read_{$forum['fid']}" /></td>
<td rowspan="2" class="{$bgcolor}" valign="top">
<strong><a href="{$forum_url}">{$forum['name']}</a></strong>{$forum_viewers_text}<div class="smalltext">{$forum['description']}{$modlist}{$subforums}</div>
</td>
<td colspan="2" class="{$bgcolor}" valign="top" align="right" style="white-space: nowrap" colspan="2">{$lastpost}</td>
</tr>
<tr height="1">
<td class="{$bgcolor}" valign="top" align="center" style="white-space: nowrap">Postów: {$posts}{$unapproved['unapproved_posts']}</td>
<td class="{$bgcolor}" valign="top" align="center" style="white-space: nowrap">Wątków: {$threads}{$unapproved['unapproved_threads']}</td>
</tr>

Dodatkowo nagłówek tabeli:
forumbit_depth1_cat
<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder">
<thead>
<tr>
<td class="thead" colspan="4">
<div class="expcolimage"><img src="{$theme['imgdir']}/{$expcolimage}" id="cat_{$forum['fid']}_img" class="expander" alt="{$expaltext}" title="{$expaltext}" /></div>
<div><strong><a href="{$forum_url}">{$forum['name']}</a></strong><br /><div class="smalltext">{$forum['description']}</div></div>
</td>
</tr>
</thead>
<tbody style="{$expdisplay}" id="cat_{$forum['fid']}_e">
<tr>
<td class="tcat" colspan="2"><span class="smalltext"><strong>{$lang->forumbit_forum}</strong></span></td>
<td class="tcat" colspan="2" width="200" align="center"><span class="smalltext"><strong>{$lang->forumbit_lastpost}</strong></span></td>
</tr>
{$sub_forums}
</tbody>
</table>
<br />

Alles. Powinno śmigać. ;)
Żadna sprawa nie jest przegrana dopóki choć jeden szaleniec o nią walczy. Tylko wariaci są coś warci.
(31.07.2011, 14:18)Adrian napisał(a): forumbit_depth2_cat i forumbit_depth2_forum
<td colspan="2" class="{$bgcolor}" valign="top" align="right" style="white-space: nowrap" colspan="2">{$lastpost}</td>

Tu jest podwójnie colspan...

Dupa wyszła... Bo ja nie mam .tcat i te tabelki nie są niestety są nie równe...

Wyglądają tak:
   

A twój kod zmodyfikowany przeze mnie, wygląda tak:
forumbit_depth2_cat i forumbit_depth2_forum
<tr>

<td rowspan="2" class="{$bgcolor}" align="center" valign="top"
width="1"><img src="{$theme['imgdir']}/{$lightbulb['folder']}.gif"
alt="{$lightbulb['altonoff']}" title="{$lightbulb['altonoff']}"
class="ajax_mark_read" id="mark_read_{$forum['fid']}" /></td>

<td rowspan="2" class="{$bgcolor}" valign="top">

<strong><a
href="{$forum_url}">{$forum['name']}</a></strong>{$forum_viewers_text}<div

class="smalltext">{$forum['description']}{$modlist}{$subforums}</div>

</td>

<td colspan="2" class="{$bgcolor}" valign="top" align="right"
style="white-space: nowrap">{$lastpost}</td>

</tr>

<tr height="1">

<td class="{$bgcolor}" valign="top" align="center"
style="white-space: nowrap">Postów:
{$posts}{$unapproved['unapproved_posts']}</td>

<td class="{$bgcolor}" valign="top" align="center"
style="white-space: nowrap">Wątków:
{$threads}{$unapproved['unapproved_threads']}</td>

</tr>

forumbit_depth1_cat
<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder">
<thead>
<tr>
<td class="thead" colspan="5">
<div class="expcolimage"><img src="{$theme['imgdir']}/{$expcolimage}" id="cat_{$forum['fid']}_img" class="expander" alt="{$expaltext}" title="{$expaltext}" /></div>
<div class="smalltext">{$forum['description']}</div>
<div><strong><a href="{$forum_url}">{$forum['name']}</a></strong><br /></div>
</td>
</tr>
</thead>
<tbody style="{$expdisplay}" id="cat_{$forum['fid']}_e">
<tr>
<td class="thead" style="padding:0" colspan="2"/>
<td class="thead" style="padding:0" width="190"/>
</tr>
{$sub_forums}
</tbody>
</table>
<br />

Adrian... POMOCY! :D

Liczę na jakąkolwiek pomoc, ja też wam mogę pomóc jeśli chodzi o grafikę. ;)
Powinno działać:

forumbit_depth2_cat i forumbit_depth2_forum:
<tr>
<td rowspan="2" class="{$bgcolor}" align="center" valign="top" width="1"><img src="{$theme['imgdir']}/{$lightbulb['folder']}.gif" alt="{$lightbulb['altonoff']}" title="{$lightbulb['altonoff']}" class="ajax_mark_read" id="mark_read_{$forum['fid']}" /></td>
<td rowspan="2" class="{$bgcolor}" valign="top">
<strong><a href="{$forum_url}">{$forum['name']}</a></strong>{$forum_viewers_text}<div class="smalltext">{$forum['description']}{$modlist}{$subforums}</div>
</td>
<td colspan="2" class="{$bgcolor}" valign="top" align="right" style="white-space: nowrap" width="260">{$lastpost}</td>
</tr>
<tr height="1">
<td class="{$bgcolor}" valign="top" align="center" style="white-space: nowrap" width="130">Postów: {$posts}{$unapproved['unapproved_posts']}</td>
<td class="{$bgcolor}" valign="top" align="center" style="white-space: nowrap" width="130">Wątków: {$threads}{$unapproved['unapproved_threads']}</td>
</tr>

forumbit_depth1_cat
<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder">
<thead>
<tr>
<td class="thead" colspan="5">
<div class="expcolimage"><img src="{$theme['imgdir']}/{$expcolimage}" id="cat_{$forum['fid']}_img" class="expander" alt="{$expaltext}" title="{$expaltext}" /></div>
<div class="smalltext">{$forum['description']}</div>
<div><strong><a href="{$forum_url}">{$forum['name']}</a></strong><br /></div>
</td>
</tr>
</thead>
<tbody style="{$expdisplay}" id="cat_{$forum['fid']}_e">
{$sub_forums}
</tbody>
</table>
<br />

P.S. Skopiuj sobie kod do np. Notepada++ a dopiero potem w szablony. Tag CODE trochę psuje kod po skopiowaniu.
Żadna sprawa nie jest przegrana dopóki choć jeden szaleniec o nią walczy. Tylko wariaci są coś warci.
Działa!
Dziękuję ci baaaarzdo serdecznie, za "stracony" dla mnie czas. Mam nadzieje, że nie tylko dla mnie. ;)
(Może by dodać to jako "wspólne(?)" dzieło do Wiki? ;)

Jak już mówiłem jesteś cudowny i jeszcze raz dziękuję oraz pozdrawiam.
Witam chciałbym jeszcze w forumbit_depth1_cat

Zrobić żeby było nad tym wszystkim jeszcze n tcat: Dział Ostatni post
coś takiego: [Obrazek: 99594824306083139264.png]
można by prosic jeszcze jedna zawartość szablonu mianowicie: forumdisplay_subforums


Załączone pliki Miniatury
   
dokładnie tak samo mam
juz sobie poradziłem działa prawidłowo
moze byś się podzielił rozwiazaniem?
(25.08.2011, 19:43)radekchyzynski napisał(a): moze byś się podzielił rozwiazaniem?

Jasne ale za darmo.....? Żartowałem :)

<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="4" class="tborder"><tr><td class="thead" colspan="5" align="center"><strong>{$lang->sub_forums_in}</strong></td></tr><tr><td class="tcat" colspan="2"><span class="smalltext"><strong>{$lang->forumbit_forum}</strong></span></td><td class="tcat" colspan="2" width="200" align="center"><span class="smalltext"><strong>{$lang->forumbit_lastpost}</strong></span></td></tr>{$forums}</table><br />

wklej i po kłopocie
dobra mam thx
Kamar napisał 27.08.2011, 14:29:
Akcja DZIĘKUJĘ ZA POMOC :)
to jest cały tyle że tyczy się problemu mojego wklej do forumdisplay_subforums
Teraz ja mam problem, a mianowicie jak wyrównać te tabelki? Chcę by były tej samej szerokości.

Daje screena problemu:

[Obrazek: blamz.png]
Masz inne wartości szerokości tej 1 tabeli w obu plikach depth2 zrób taką samą w



Użytkownicy przeglądający ten wątek:

1 gości