Edytujemy plik forum/index.php, zaraz po:
opentable($locale['400']);
szukamy:
echo "<!--pre_forum_idx--><table cellpadding='0' cellspacing='1' width='100%' class='tbl-border forum_idx_table'>\n<tr>\n";
echo "<td colspan='2' class='tbl2'>".$locale['401']."</td>\n";
echo "<td align='center' width='1%' class='tbl2' style='white-space:nowrap'>".$locale['402']."</td>\n";
echo "<td align='center' width='1%' class='tbl2' style='white-space:nowrap'>".$locale['403']."</td>\n";
echo "<td width='1%' class='tbl2' style='white-space:nowrap'>".$locale['404']."</td>\n";
echo "</tr>\n";
I usuwamy.
Szukamy:
if ($data['forum_cat_name'] != $current_cat) {
$current_cat = $data['forum_cat_name'];
echo "<tr>\n<td colspan='5' class='forum-caption forum_cat_name'><!--forum_cat_name-->".$data['forum_cat_name']."</td>\n</tr>\n";
}
zamieniamy na:
if ($data['forum_cat_name'] != $current_cat) {
$current_cat = $data['forum_cat_name'];
echo "<table cellpadding='0' cellspacing='1' width='100%' class='tbl-border' style='margin-bottom:10px;'><tr>\n";
echo "<td colspan='2' class='forum-caption'><center><strong>".$data['forum_cat_name']."</strong></center></td>\n";
echo "<td align='center' width='1%' class='forum-caption' style='white-space:nowrap'>".$locale['402']."</td>\n";
echo "<td align='center' width='1%' class='forum-caption' style='white-space:nowrap'>".$locale['403']."</td>\n";
echo "<td width='20%' class='forum-caption' style='white-space:nowrap' align='center'>".$locale['404']."</td>\n";
echo "</tr>\n";
}
Szukamy:
echo "<tr>\n";
echo "<td align='center' width='1%' class='tbl2' style='white-space:nowrap'>$fim</td>\n";
echo "<td class='tbl1 forum_name'><!--forum_name--><a href='viewforum.php?forum_id=".$data['forum_id']."'>".$data['forum_name']."</a><br />\n";
if ($data['forum_description'] || $moderators) {
echo "<span class='small'>".$data['forum_description'].($data['forum_description'] && $moderators ? "<br />\n" : "");
echo ($moderators ? "<strong>".$locale['411']."</strong>".$moderators."</span>\n" : "</span>\n")."\n";
}
echo "</td>\n";
echo "<td align='center' width='1%' class='tbl2' style='white-space:nowrap'>".$data['forum_threadcount']."</td>\n";
echo "<td align='center' width='1%' class='tbl1' style='white-space:nowrap'>".$data['forum_postcount']."</td>\n";
echo "<td width='1%' class='tbl2' style='white-space:nowrap'>";
if ($data['forum_lastpost'] == 0) {
echo $locale['405']."</td>\n</tr>\n";
} else {
echo showdate("forumdate", $data['forum_lastpost'])."<br />\n";
echo "<span class='small'>".$locale['406']."<a href='".BASEDIR."profile.php?lookup=".$data['forum_lastuser']."'>".$data['user_name']."</a></span></td>\n";
echo "</tr>\n";
}
}
} else {
echo "<tr>\n<td colspan='5' class='tbl1'>".$locale['407']."</td>\n</tr>\n";
}
echo "</table><!--sub_forum_idx_table-->\n<table cellpadding='0' cellspacing='0' width='100%'>\n<tr>\n";
i zamieniamy na:
echo "<tr>\n";
echo "<td align='center' width='1%' class='tbl2' style='white-space:nowrap'>$fim</td>\n";
echo "<td class='tbl1 forum_name_cell'><!--forum_name_cell--><a href='viewforum.php?forum_id=".$data['forum_id']."' style='font-weight:bold;font-size:13px;'>".$data['forum_name']."</a><br />\n";
if ($data['forum_description'] || $moderators) {
echo $data['forum_description'].($data['forum_description'] && $moderators ? "<br />\n" : "");
echo ($moderators ? "<span class='small'>".$locale['411'].$moderators."</span>" : "</span>\n")."\n";
}
echo "</td>\n";
echo "<td align='center' width='1%' class='tbl2' style='white-space:nowrap'>".$data['forum_threadcount']."</td>\n";
echo "<td align='center' width='1%' class='tbl1' style='white-space:nowrap'>".$data['forum_postcount']."</td>\n";
echo "<td width='20%' class='tbl2' style='white-space:nowrap'>";
if ($data['forum_lastpost'] == 0) {
echo $locale['405']."</td>\n</tr>\n";
} else {
echo showdate("forumdate", $data['forum_lastpost'])."<br />\n";
echo "<span class='small'>".$locale['406']."<a href='".BASEDIR."profile.php?lookup=".$data['forum_lastuser']."'>".trimlink($data['user_name'],15)."</a></span></td>\n";
echo "</tr>\n";
if ($data['forum_cat_name'] != $current_cat) {
echo "</table>";
}
}
}
} else {
echo "<table cellpadding='0' cellspacing='1' width='100%' class='tbl-border' style='margin-bottom:10px;'><tr>\n<td colspan='5' class='tbl1'>".$locale['407']."</td>\n</tr></table>\n";
}
echo "<!--sub_forum_idx_table-->\n<table cellpadding='0' cellspacing='0' width='100%'>\n<tr>\n";
Po tych zabiegach nasze forum będzie wyglądało mniej-więcej tak jak w PHPBB :).
W załączniku gotowy plik.
Pozdro!
bartek124 dodał/a następującą plik:
Nie pomagam na komunikatorach oraz PW!
|