function openside($title, $collapse = false, $state = "on") { static $box_id = 0; $box_id++; global $panel_collapse; $panel_collapse = $collapse; echo "<h3 class='panelcap'>" . ($collapse ? panelbutton($state, $box_id) : "") . "{$title}</h3>\n<div class='panelbody'>\n\t" . ($collapse ? panelstate($state, $box_id) : ""); }
function openside($title, $collapse = false, $state = "on") { global $panel_collapse; $panel_collapse = $collapse; echo "<div class='border'>\n"; echo "<div class='scapmain'>"; if ($collapse == true) { $boxname = str_replace(" ", "", $title); echo "<div style='float:right;'>" . panelbutton($state, $boxname) . "</div>"; } echo $title . "</div>\n<div class='side-body floatfix'>\n"; if ($collapse == true) { echo panelstate($state, $boxname); } }
function openside($title, $collapse = FALSE, $state = "on") { global $panel_collapse; $panel_collapse = $collapse; echo "<div class='heading'>\n"; echo "<div style='margin-left: 10px;'>" . $title . "</div>\n"; echo "</div>\n"; if ($collapse == TRUE) { $boxname = str_replace(" ", "", $title); echo "<div class='pull-right' style='padding-top: 10px;'>" . panelbutton($state, $boxname) . "</div>\n"; } echo "<div class='content'>\n"; if ($collapse == TRUE) { echo panelstate($state, $boxname); } }
function openside($title, $collapse = false, $state = "on") { global $panel_collapse; $panel_collapse = $collapse; echo "<table cellpadding='0' cellspacing='0' width='100%' class='border'>\n<tr>\n"; echo "<td class='scapmain'>" . $title . "</td>\n"; if ($collapse == true) { $boxname = str_replace(" ", "", $title); echo "<td class='scapmain' align='right'>" . panelbutton($state, $boxname) . "</td>\n"; } echo "</tr>\n<tr>\n"; echo "<td" . ($collapse == true ? " colspan='2'" : "") . " class='side-body'>\n"; if ($collapse == true) { echo panelstate($state, $boxname); } }
function openside($title, $collapse = false, $state = "on") { static $box_id = 0; $box_id++; global $panel_collapse, $p_data; $panel_collapse = $collapse; if ($p_data['panel_filename'] == "css_navigation_panel") { $panel_collapse = false; echo "<div class='panelbody navigation'><div class='navcap_r'><div class='navcap_l'><div class='panel_r'><div class='panel_l'>"; } else { echo "<h3 class='panelcap'><span><span>" . ($collapse ? panelbutton($state, $box_id) : "") . "{$title}</span></span></h3>\r\n<div class='panelbody'><div class='panel_r'><div class='panel_l'>\n\t" . ($collapse ? panelstate($state, $box_id) : ""); } }
function opensidex($title, $state = "on") { $boxname = str_replace(" ", "", $title); echo "<table cellpadding='0' cellspacing='0' width='100%' class='border'>\n<tr>\n<td class='scapmain'>{$title}</td>\n<td class='scapmain' align='right'>" . panelbutton($state, $boxname) . "</td>\n</tr>\n<tr>\n<td colspan='2' class='side-body'>\n<div id='box_{$boxname}'" . ($state == "off" ? " style='display:none'" : "") . ">\n"; }
function renderSubforums($forum) { global $locale, $userdata, $db_prefix, $lastvisited, $fb4; $forum_list = ""; $current_cat = ""; $result = dbquery("SELECT f.*, f2.forum_name AS forum_cat_name, u.user_id, u.user_name\n\t\tFROM " . DB_FORUMS . " f\n\t\tLEFT JOIN " . DB_FORUMS . " f2 ON f.forum_cat = f2.forum_id\n\t\tLEFT JOIN " . DB_USERS . " u ON f.forum_lastuser = u.user_id\n\t\tLEFT JOIN " . DB_PREFIX . "fb_forums f3 on f3.forum_id=f.forum_id\n\t\tWHERE " . groupaccess('f.forum_access') . " AND f3.forum_parent='" . $forum . "' GROUP BY forum_id ORDER BY f2.forum_order ASC, f.forum_order ASC"); if (dbrows($result) != 0) { $state = "off"; $boxname = "subforums"; echo "<!--pre_forum_idx--><table cellpadding='0' cellspacing='1' width='100%' class='tbl-border'>\n"; if ($fb4['forum_icons']) { echo "<tr>\n<td colspan='6' class='forum-caption' style='padding:7px;'><div style='float:right'>" . panelbutton($state, $boxname) . "</div>\n\n\t\t\t<!--forum_cat_name_cell-->" . $locale['fb553'] . "</td>\n</tr>"; echo "</table>" . panelstate($state, $boxname) . "<table cellpadding='0' cellspacing='1' width='100%' class='tbl-border'>\n"; echo "<tr>\n<td colspan='3' class='tbl2' width='65%'>" . $locale['401'] . "</td>\n"; } else { echo "<tr>\n<td colspan='6' class='forum-caption' style='padding:7px;'><div style='float:right'>" . panelbutton($state, $boxname) . "</div>\n\n\t\t\t<!--forum_cat_name_cell-->" . $locale['fb553'] . "</td>\n</tr>"; echo "</table>" . panelstate($state, $boxname) . "<table cellpadding='0' cellspacing='1' width='100%' class='tbl-border'>\n"; echo "<tr>\n<td colspan='2' class='tbl2' width='65%'>" . $locale['401'] . "</td>\n"; } echo "<td class='tbl2' width='35%' style='white-space:nowrap'>" . $locale['404'] . "</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 "</tr>\n"; while ($data = dbarray($result)) { $moderators = ""; if ($data['forum_moderators']) { $mod_groups = explode(".", $data['forum_moderators']); foreach ($mod_groups as $mod_group) { if ($moderators) { $moderators .= ", "; } $moderators .= $mod_group < 101 ? "<a href='" . BASEDIR . "profile.php?group_id=" . $mod_group . "'>" . getgroupname($mod_group) . "</a>" : getgroupname($mod_group); } } $forum_match = "\\|" . $data['forum_lastpost'] . "\\|" . $data['forum_id']; if ($data['forum_lastpost'] > $lastvisited) { if (iMEMBER && preg_match("({$forum_match}\\.|{$forum_match}\$)", $userdata['user_threads'])) { $fim = "<img src='" . get_image("folder") . "' alt='" . $locale['561'] . "' />"; } else { $fim = "<img src='" . get_image("foldernew") . "' alt='" . $locale['560'] . "' />"; } } else { $fim = "<img src='" . get_image("folder") . "' alt='" . $locale['561'] . "' />"; } echo "<tr>\n"; echo "<td align='center' width='1%' class='tbl1' style='white-space:nowrap' style='padding:7px;'>{$fim}</td>\n"; $iconQuery = dbquery("select * from " . $db_prefix . "fb_forums where forum_id='" . $data['forum_id'] . "'"); if (dbrows($iconQuery)) { $iconData = dbarray($iconQuery); $ficon = $iconData['forum_icon'] !== "" ? $iconData['forum_icon'] : "folder.png"; } else { $ficon = "folder.png"; } if ($fb4['forum_icons']) { $ficon = "<img src='" . INFUSIONS . "fusionboard4/images/forum_icons/{$ficon}' alt='' />"; echo "<td align='center' width='1%' class='tbl2' style='white-space:nowrap; padding:7px;'>{$ficon}</td>\n"; } echo "<td class='tbl1' style='padding:5px;width:65%;'><a href='viewforum.php?forum_id=" . $data['forum_id'] . "' style='font-size:12px; text-decoration:underline; font-weight:bold;'>\n\t\t\t<!--forum_name_cell-->" . $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"; } $c_res = dbquery("select * from " . DB_PREFIX . "forums f\n\t\t\tleft join " . DB_PREFIX . "fb_forums f2 on f2.forum_id=f.forum_id\n\t\t\twhere " . groupaccess("f.forum_access") . " AND f2.forum_parent='" . $data['forum_id'] . "'"); if (dbrows($c_res)) { if ($fb4['subforum_view']) { echo "<br /><span class='small'><strong>" . $locale['fb552'] . "</strong> "; $i = dbrows($c_res); while ($c_data = dbarray($c_res)) { $i--; echo "<a href='" . FORUM . "viewforum.php?forum_id=" . $c_data['forum_id'] . "'>" . $c_data['forum_name'] . "</a>"; if ($i > 0) { echo ", "; } } echo "</span>"; } else { $counter = 0; $rows = 3; $sfimage1 = file_exists(THEME . "images/folder_open.png") ? THEME . "images/folder_open.png" : INFUSIONS . "fusionboard4/images/folder_open.png"; $sfimage2 = file_exists(THEME . "images/subforum.png") ? THEME . "images/subforum.png" : INFUSIONS . "fusionboard4/images/subforum.png"; echo "<br /><img src='{$sfimage1}' alt='' style='vertical-align:middle;'> <span class='small' style='font-weight:bold;'>" . $locale['fb552'] . "</span><br />"; echo "<table cellspacing='0' cellpadding='0' border='0' width='100%' style='padding-left:10px;'><tr>\n\t\t\t\t\t<td width='50%' class='small' style='padding-left:3px; padding-right:3px; vertical-align:top;'>"; while ($c_data = dbarray($c_res)) { if ($counter != 0 && $counter % $rows == 0) { echo "</td><td width='50%' class='small' style='padding-left:3px; padding-right:3px; vertical-align:top;'>\n"; } $subforum = is_file(THEME . "images/subforum.png") ? THEME . "images/subforum.png" : INFUSIONS . "fusionboard4/images/subforum.png"; echo "<img src='{$sfimage2}' alt='' style='vertical-align:middle;'> \n\t\t\t\t\t\t<a href='" . FORUM . "viewforum.php?forum_id=" . $c_data['forum_id'] . "' class='small'>" . $c_data['forum_name'] . "</a><br />"; $counter++; } echo "</td></tr></table>"; } } echo "</td>\n"; echo "<td class='tbl2' style='white-space:nowrap; padding:5px;width:35%;'>"; $children = array(); $child_res = dbquery("select * from " . $db_prefix . "fb_forums f\n\t\t\tleft join " . $db_prefix . "forums f2 on f2.forum_id=f.forum_id\n\t\t\twhere " . groupaccess("f2.forum_access") . " and f.forum_parent='" . $data['forum_id'] . "'"); if (dbrows($child_res)) { while ($child_data = dbarray($child_res)) { array_push($children, $child_data['forum_id']); findChildren($child_data['forum_id']); } } if (count($children)) { $where = ""; $counter = count($children); foreach ($children as $child) { $where .= "t.forum_id='{$child}' " . ($counter > 1 ? "OR " : ""); $counter--; } $childrenForums = dbquery("select * from " . $db_prefix . "threads t\n\t\t\t\tleft join " . $db_prefix . "users u on u.user_id=t.thread_lastuser\n\t\t\t\tleft join " . $db_prefix . "posts p on p.post_id=t.thread_lastpostid\n\t\t\t\twhere ({$where} OR t.forum_id='" . $data['forum_id'] . "') \n\t\t\t\torder by t.thread_lastpost desc limit 1"); if (!dbrows($childrenForums)) { echo $locale['405'] . "</td>\n"; } else { $childrenData = dbarray($childrenForums); echo "<b><a href='viewthread.php?thread_id=" . $childrenData['thread_id'] . "' style='text-decoration:underline;'>" . trimlink($childrenData['thread_subject'], 30) . "</a></b><br />"; echo "" . $locale['406'] . "<a href='" . BASEDIR . "profile.php?lookup=" . $childrenData['thread_lastuser'] . "'>" . showLabel($childrenData['user_id'], false, "index") . "</a><br />\n\t\t\t\t\t<div align='right'>" . timePassed($childrenData['thread_lastpost'], false) . "\n\t\t\t\t\t<a href='" . FORUM . "viewthread.php?thread_id=" . $childrenData['thread_id'] . "&pid=" . $childrenData['thread_lastpostid'] . "#post_" . $childrenData['thread_lastpostid'] . "' title='Go To Last Post'><b>»</b></a></div></td>\n"; } } else { if ($data['forum_lastpost'] == 0) { echo $locale['405'] . "</td>\n"; } else { $threadData = dbarray(dbquery("select * from " . $db_prefix . "threads t\n\t\t\t\t\tleft join " . $db_prefix . "posts p on p.post_id=t.thread_lastpostid\n\t\t\t\t\twhere t.thread_lastpost='" . $data['forum_lastpost'] . "'")); echo "<b><a href='viewthread.php?thread_id=" . $threadData['thread_id'] . "' style='text-decoration:underline;'>" . trimlink($threadData['thread_subject'], 30) . "</a></b><br />"; echo "" . $locale['406'] . "<a href='" . BASEDIR . "profile.php?lookup=" . $data['forum_lastuser'] . "' style='text-decoration:underline;'>" . showLabel($data['forum_lastuser'], false, "index") . "</a><br />\n\t\t\t\t\t<div align='right'>" . timePassed($data['forum_lastpost'], false) . "\n\t\t\t\t\t<a href='" . FORUM . "viewthread.php?thread_id=" . $threadData['thread_id'] . "&pid=" . $threadData['thread_lastpostid'] . "#post_" . $threadData['thread_lastpostid'] . "' title='Go To Last Post'><b>»</b></a></div></td>\n"; } } echo "<td align='center' width='1%' class='tbl1' style='white-space:nowrap'>" . $data['forum_threadcount'] . "</td>\n"; echo "<td align='center' width='1%' class='tbl2' style='white-space:nowrap'>" . $data['forum_postcount'] . "</td>\n"; echo "</tr>\n"; } echo "</table></div>"; } }
function renderForum($data2, $result2, $k, $indent = "") { global $aidlink, $locale; $forumR = ""; $forumR .= "<tr>\n"; $forumR .= "<td class='tbl1'>{$indent}<span class='alt'>" . $data2['forum_name']; if (dbcount("(forum_id)", DB_PREFIX . "fb_forums", "forum_parent='" . $data2['forum_id'] . "'")) { $forumR .= " " . panelbutton("off", "forum" . $data2['forum_id']); } $forumR .= "</span>\n"; $forumR .= "[<a href='" . FUSION_SELF . $aidlink . "&section=forums&action=prune&forum_id=" . $data2['forum_id'] . "'>" . $locale['563'] . "</a>]<br />\n"; $forumR .= ($data2['forum_description'] ? "{$indent}<span class='small'>" . $data2['forum_description'] . "</span>" : "") . "</td>\n"; $forumR .= "<td align='center' width='1%' class='tbl2' style='white-space:nowrap'>" . $data2['forum_order'] . "</td>\n"; $forumR .= "<td align='center' width='1%' class='tbl1' style='white-space:nowrap'>\n"; $parent = $data2['forum_parent'] > 0 ? "&parent=" . $data2['forum_parent'] : ""; if (dbrows($result2) != 1) { $up = $data2['forum_order'] - 1; $down = $data2['forum_order'] + 1; if ($k == 1) { $forumR .= "<a href='" . FUSION_SELF . $aidlink . "&section=forums&action=md&order={$down}&forum_id=" . $data2['forum_id'] . "&t=forum&cat=" . $data2['forum_cat'] . "{$parent}'><img src='" . get_image("down") . "' alt='" . $locale['557'] . "' title='" . $locale['557'] . "' style='border:0px;' /></a>\n"; } elseif ($k < dbrows($result2)) { $forumR .= "<a href='" . FUSION_SELF . $aidlink . "&section=forums&action=mu&order={$up}&forum_id=" . $data2['forum_id'] . "&t=forum&cat=" . $data2['forum_cat'] . "{$parent}'><img src='" . get_image("up") . "' alt='" . $locale['556'] . "' title='" . $locale['558'] . "' style='border:0px;' /></a>\n"; $forumR .= "<a href='" . FUSION_SELF . $aidlink . "&section=forums&action=md&order={$down}&forum_id=" . $data2['forum_id'] . "&t=forum&cat=" . $data2['forum_cat'] . "{$parent}'><img src='" . get_image("down") . "' alt='" . $locale['557'] . "' title='" . $locale['557'] . "' style='border:0px;' /></a>\n"; } else { $forumR .= "<a href='" . FUSION_SELF . $aidlink . "&section=forums&action=mu&order={$up}&forum_id=" . $data2['forum_id'] . "&t=forum&cat=" . $data2['forum_cat'] . "{$parent}'><img src='" . get_image("up") . "' alt='" . $locale['556'] . "' title='" . $locale['558'] . "' style='border:0px;' /></a>\n"; } } $forumR .= "</td>\n"; $forumR .= "<td align='center' width='1%' class='tbl1' style='white-space:nowrap'><a href='" . FUSION_SELF . $aidlink . "&section=forums&action=edit&forum_id=" . $data2['forum_id'] . "&t=forum'>" . $locale['554'] . "</a> ::\n"; $forumR .= "<a href='" . FUSION_SELF . $aidlink . "&section=forums&action=delete&forum_id=" . $data2['forum_id'] . "&t=forum{$parent}' onclick=\"return confirm('" . $locale['570'] . "');\">" . $locale['555'] . "</a></td>\n"; $forumR .= "</tr>\n"; return $forumR; }
$current_cat = $data['forum_cat_name']; $forumStatus = $forumCollapsed ? "off" : "on"; $boxname = "forum_" . $data['forum_id']; $element = "tbody"; if ($i == 0) { echo "<!--pre_forum_idx-->"; } echo "<table class='tbl-border forum_idx_table' id='forum_cat_" . $data['forum_cat'] . "' cellpadding='0' cellspacing='0' width='100%'>\n<thead>\n<tr class='forum-cat-head'>\n"; echo "<td class='forum-caption forum_cat_name' colspan='2'><!--forum_cat_name-->"; echo "<h3><a href='" . FORUM . "index.php?cat=" . $data['forum_cat'] . "'>" . $data['forum_cat_name'] . "</a></h3>"; if ($data['forum_cat_description']) { echo "<span class='forum-cat-description small'>" . nl2br(parseubb($data['forum_cat_description'])) . "</span>"; } echo "</td>\n"; echo "<td class='forum-caption' width='12%' style='white-space:nowrap'>" . $locale['402'] . " / " . $locale['403'] . "</td>\n"; echo "<td class='forum-caption' width='160'><span class='flleft'>" . $locale['404'] . "</span>" . ($forumCollapse ? "<div class='flright'>" . panelbutton($forumStatus, $boxname) . "</div>\n" : "") . "</td>\n"; echo "</tr>\n</thead>\n"; echo $forumCollapse ? "" . panelstate($forumStatus, $boxname, "tbody") . "\n" : "<tbody>"; } $i++; $moderators = ""; if ($data['forum_moderators']) { $mod_groups = explode(".", $data['forum_moderators']); foreach ($mod_groups as $mod_group) { if ($moderators) { $moderators .= ", "; } $moderators .= $mod_group < 101 ? "<a href='" . BASEDIR . "profile.php?group_id=" . $mod_group . "'>" . getgroupname($mod_group) . "</a>" : getgroupname($mod_group); } } $forum_match = "\\|" . $data['forum_lastpost'] . "\\|" . $data['forum_id'];
function openside($title, $collapse = FALSE, $state = "on") { global $panel_collapse; $panel_collapse = $collapse; echo "<table cellpadding='0' cellspacing='0' width='100%'>\n<tr>\n"; echo "<td class='scapmain-left'></td>\n"; echo "<td class='scapmain'>" . $title . "</td>\n"; if ($collapse == TRUE) { $boxname = str_replace(" ", "", $title); echo "<td class='scapmain' align='right'>" . panelbutton($state, $boxname) . "</td>\n"; } echo "<td class='scapmain-right'></td>\n"; echo "</tr>\n</table>\n"; echo "<table cellpadding='0' cellspacing='0' width='100%' class='spacer'>\n<tr>\n"; echo "<td class='side-body'>\n"; if ($collapse == TRUE) { echo panelstate($state, $boxname); } }
function openside($title, $collapse = false, $state = "on") { global $panel_collapse; $panel_collapse = $collapse; echo "<div class='scapmain-top'></div>\n"; echo "<div class='scapmain floatfix clearfix'>\n"; echo "<div class='flleft'>" . $title . "</div>\n"; if ($collapse == true) { $boxname = str_replace(" ", "", $title); echo "<div class='flright' style='padding-top: 2px;'>" . panelbutton($state, $boxname) . "</div>\n"; } echo "</div>\n"; echo "<div class='side-body floatfix spacer'>\n"; if ($collapse == true) { echo panelstate($state, $boxname); } }
function openside($title, $collapse = false, $state = "on") { global $panel_collapse; $panel_collapse = $collapse; echo "<table cellpadding='0' cellspacing='0' width='100%' class='sidetop'>\n<tr>\n\t<td class='paneltext'>{$title}</td>\n"; if ($collapse == true) { $boxname = str_replace(" ", "", $title); echo "<td>" . panelbutton($state, $boxname) . "</td>\n"; } echo "</tr>\n</table>\n<table cellpadding='0' cellspacing='0' width='100%'>\n<tr>\n\t<td class='sidemid'>\n"; if ($collapse == true) { echo panelstate($state, $boxname); } }
function openside($title, $collapse = false, $state = "on") { global $panel_collapse; $panel_collapse = $collapse; echo "<table cellpadding='0' cellspacing='0' width='100%'>\n<tr>\n"; echo "<td><img src='" . THEME . "/images/pfboxscapleft.jpg' alt='image' /></td>\n"; echo "<td class='scapmain' width='100%' align='center'>{$title}</td>\n"; if ($collapse == true) { $boxname = str_replace(" ", "", $title); echo "<td class='scapmain' align='right'>" . panelbutton($state, $boxname) . "</td>\n"; } echo "<td><img src='" . THEME . "/images/pfboxscapright.jpg' alt='image' /></td>\n"; echo "</tr>\n</table>\n"; echo "<table cellpadding='0' cellspacing='0' width='100%' align='center'>\n<tr>\n"; echo "<td class='pfboxbll' height='100%'> </td>\n"; echo "<td class='side-body'>\n"; if ($collapse == true) { echo panelstate($state, $boxname); } }
function openside($title, $collapse = false, $state = "on") { static $box_id = 0; $box_id++; global $panel_collapse, $p_data; $panel_collapse = $collapse; if ($p_data['panel_filename'] == "css_navigation_panel") { $title = ""; } opentable(($collapse ? panelbutton($state, $box_id) : "") . $title); echo $collapse ? panelstate($state, $box_id) : ""; }
echo "<input type='submit' name='search' value='" . $locale['550'] . "' class='button' />\n"; echo "</form>\n</td>\n</tr>\n</table><!--sub_forum_idx-->\n"; $newest = dbarray(dbquery("select * from " . DB_USERS . " order by user_id desc limit 1")); $search = array("{POSTS}", "{THREADS}", "{USERS}", "{NEW}", "{ONLINE}", "{COUNT}", "{DATE}", "{RATINGS}"); $replace = array("<b>" . number_format(dbrows(dbquery("SELECT * FROM " . DB_POSTS))) . "</b>", "<b>" . number_format(dbrows(dbquery("SELECT * FROM " . DB_THREADS))) . "</b>", "<b>" . number_format(dbrows(dbquery("SELECT * FROM " . DB_USERS))) . "</b>", "<b><a href='" . BASEDIR . "profile.php?lookup=" . $newest['user_id'] . "'>" . $newest['user_name'] . "</a></b>", "<b>" . number_format(dbrows(dbquery("SELECT * FROM " . DB_PREFIX . "online"))) . "</b>", "<b>" . number_format($fb4['stat_moau']) . "</b>", "<b>" . strftime("%B %d %Y, %I:%M %p", $fb4['stat_moau_date']) . "</b>", "<b>" . number_format(dbrows(dbquery("SELECT * FROM " . DB_PREFIX . "fb_rate"))) . "</b>"); $result = dbquery("SELECT ton.*, tu.user_id,user_name,user_level FROM " . DB_ONLINE . " ton\n\tLEFT JOIN " . DB_USERS . " tu ON ton.online_user=tu.user_id"); $guests = 0; $members = array(); while ($data = dbarray($result)) { if ($data['online_user'] !== "0") { array_push($members, array($data['user_id'], $data['user_name'], $data['user_level'])); } } $state = "on"; $boxname = "statistics"; echo "<br />\n\t<table width='100%' cellspacing='1' cellpadding='0' class='tbl-border'>\n\t<tr>\n\t\t<td colspan='2' class='forum-caption' style='padding:7px;'><div style='float:right'>" . panelbutton($state, $boxname) . "</div>\n" . $locale['fb554'] . "</td>\n\t</tr>\n\t</table>\n\t" . panelstate($state, $boxname) . "\n\t<table width='100%' cellspacing='1' cellpadding='0' class='tbl-border'>\n\t<tr>\n\t\t<td colspan='2' class='tbl2' style='font-weight:bold'>" . str_replace($search, $replace, $locale['fb559']) . "</td>\n\t</tr>\n\t<tr>\n"; $levels = dbquery("select * from " . DB_PREFIX . "fb_labels \n\t\twhere (label_group > 100 and label_group < 104) or (label_group=0 and label_user=0) order by label_group desc"); $groups = dbquery("select * from " . DB_PREFIX . "fb_labels l\n\t\tleft join " . DB_USER_GROUPS . " g on g.group_id=l.label_group\n\t\twhere l.label_user='******' and (l.label_group != '0' and l.label_group != '101' and l.label_group != '102' \n\t\t\t\t\t\t\t\t\tand l.label_group !='103') order by g.group_name asc"); $counter = dbrows($levels) + dbrows($groups); $labels = ""; if (dbrows($levels)) { while ($level_data = dbarray($levels)) { $labels .= "<span style='" . $level_data['label_style'] . "'>" . getgroupname($level_data['label_group']) . "</span>" . ($counter > 1 ? ", " : ""); $counter--; } } if (dbrows($groups)) { while ($group_data = dbarray($groups)) { $labels .= "<span style='" . $group_data['label_style'] . "'>" . $group_data['group_name'] . "</span>" . ($counter > 1 ? ", " : ""); $counter--; }