• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP begin_table函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中begin_table函数的典型用法代码示例。如果您正苦于以下问题:PHP begin_table函数的具体用法?PHP begin_table怎么用?PHP begin_table使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了begin_table函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: commenttable_new

function commenttable_new($rows)
{
    global $CURUSER, $HTTP_SERVER_VARS;
    begin_main_frame();
    begin_frame();
    $count = 0;
    foreach ($rows as $row) {
        $subres = mysql_query("SELECT name from torrents where id=" . unsafeChar($row["torrent"])) or sqlerr(__FILE__, __LINE__);
        $subrow = mysql_fetch_array($subres);
        print "<br /><a href=\"details.php?id=" . safeChar($row["torrent"]) . "\">" . safeChar($subrow["name"]) . "</a><br />\n";
        print "<p class=sub>#" . $row["id"] . " by ";
        if (isset($row["username"])) {
            print "<a name=comm" . $row["id"] . " href=userdetails.php?id=" . safeChar($row["user"]) . "><b>" . safechar($row["username"]) . "</b></a>" . ($row["warned"] == "yes" ? "<img src=" . "pic/warned.gif alt=\"Warned\">" : "");
        } else {
            print "<a name=\"comm" . safeChar($row["id"]) . "\"><i>(orphaned)</i></a>\n";
        }
        print " at " . safeChar($row["added"]) . " GMT" . "- [<a href=comment.php?action=edit&cid={$row['id']}>Edit</a>]" . "- [<a href=deletecomment.php?id={$row['id']}>Delete</a>]</p>\n";
        $avatar = $CURUSER["avatars"] == "yes" ? safechar($row["avatar"]) : "";
        if (!$avatar) {
            $avatar = "pic/default_avatar.gif";
        }
        begin_table(true);
        print "<tr valign=top>\n";
        print "<td align=center width=150 style='padding: 0px'><img width=150 src={$avatar}></td>\n";
        print "<td class=text>" . format_comment($row["text"]) . "</td>\n";
        print "</tr>\n";
        end_table();
    }
    end_frame();
    end_main_frame();
}
开发者ID:ZenoX2012,项目名称:CyBerFuN-CoDeX,代码行数:31,代码来源:torrentcomments.php


示例2: bjtable

function bjtable($res, $frame_caption)
{
    begin_frame($frame_caption, true);
    begin_table();
    ?>
<tr>
<td class="colhead">Rank</td>
<td align="left" class="colhead">User</td>
<td align="right" class="colhead">Wins</td>
<td align="right" class="colhead">Losses</td>
<td align="right" class="colhead">Games</td>
<td align="right" class="colhead">Percentage</td>
<td align="right" class="colhead">Win/Loss</td>
</tr>
<?php 
    $num = 0;
    while ($a = mysql_fetch_assoc($res)) {
        ++$num;
        //Calculate Win %
        $win_perc = number_format($a[wins] / $a[games] * 100, 1);
        // Add a user's +/- statistic
        $plus_minus = $a[wins] - $a[losses];
        if ($plus_minus >= 0) {
            $plus_minus = mksize(($a[wins] - $a[losses]) * 100 * 1024 * 1024);
        } else {
            $plus_minus = "-";
            $plus_minus .= mksize(($a[losses] - $a[wins]) * 100 * 1024 * 1024);
        }
        print "<tr><td>{$num}</td><td align=left><table border=0 class=main cellspacing=0 cellpadding=0><tr><td class=embedded>" . "<b><a href=userdetails.php?id=" . $a[id] . ">" . $a[username] . "</a></b></td>" . "</tr></table></td><td align=right>" . number_format($a[wins], 0) . "</td>" . "</td><td align=right>" . number_format($a[losses], 0) . "</td>" . "</td><td align=right>" . number_format($a[games], 0) . "</td>" . "</td><td align=right>{$win_perc}</td>" . "</td><td align=right>{$plus_minus}</td>" . "</tr>\n";
    }
    end_table();
    end_frame();
}
开发者ID:ZenoX2012,项目名称:CyBerFuN-CoDeX,代码行数:33,代码来源:bjstats.php


示例3: bjtable

function bjtable($res, $frame_caption)
{
    $htmlout = '';
    $htmlout .= begin_frame($frame_caption, true);
    $htmlout .= begin_table();
    $htmlout .= "<tr>\r\n\t<td class='colhead'>Rank</td>\r\n\t<td class='colhead' align='left'>User</td>\r\n\t<td class='colhead' align='right'>Wins</td>\r\n\t<td class='colhead' align='right'>Losses</td>\r\n\t<td class='colhead' align='right'>Games</td>\r\n\t<td class='colhead' align='right'>Percentage</td>\r\n\t<td class='colhead' align='right'>Win/Loss</td>\r\n\t</tr>";
    $num = 0;
    while ($a = mysqli_fetch_assoc($res)) {
        ++$num;
        //==Calculate Win %
        $win_perc = number_format($a['wins'] / $a['games'] * 100, 1);
        //==Add a user's +/- statistic
        $plus_minus = $a['wins'] - $a['losses'];
        if ($plus_minus >= 0) {
            $plus_minus = mksize(($a['wins'] - $a['losses']) * 100 * 1024 * 1024);
        } else {
            $plus_minus = "-";
            $plus_minus .= mksize(($a['losses'] - $a['wins']) * 100 * 1024 * 1024);
        }
        $htmlout .= "<tr><td>{$num}</td><td align='left'>" . "<b><a href='userdetails.php?id=" . $a['id'] . "'>" . $a['username'] . "</a></b></td>" . "<td align='right'>" . number_format($a['wins'], 0) . "</td>" . "<td align='right'>" . number_format($a['losses'], 0) . "</td>" . "<td align='right'>" . number_format($a['games'], 0) . "</td>" . "<td align='right'>{$win_perc}</td>" . "<td align='right'>{$plus_minus}</td>" . "</tr>\n";
    }
    $htmlout .= end_table();
    $htmlout .= end_frame();
    return $htmlout;
}
开发者ID:CharlieHD,项目名称:U-232-V3,代码行数:25,代码来源:bjstats.php


示例4: usercommenttable

function usercommenttable($rows)
{
    global $CURUSER, $pic_base_url, $userid;
    begin_main_frame();
    begin_frame();
    $count = 0;
    foreach ($rows as $row) {
        echo "<p class=sub>#" . $row["id"] . " by ";
        if (isset($row["username"])) {
            $title = $row["title"];
            if ($title == "") {
                $title = get_user_class_name($row["class"]);
            } else {
                $title = safeChar($title);
            }
            echo "<a name=comm" . $row["id"] . " href=userdetails.php?id=" . $row["user"] . "><b>" . safeChar($row["username"]) . "</b></a>" . ($row["donor"] == "yes" ? "<img src=\"{$pic_base_url}star.gif\" alt='Donor'>" : "") . ($row["warned"] == "yes" ? "<img src=" . "\"{$pic_base_url}warned.gif\" alt=\"Warned\">" : "") . " ({$title})\n";
        } else {
            echo "<a name=\"comm" . $row["id"] . "\"><i>(orphaned)</i></a>\n";
        }
        echo " at " . $row["added"] . " GMT" . ($userid == $CURUSER["id"] || $row["user"] == $CURUSER["id"] || get_user_class() >= UC_MODERATOR ? "- [<a href=usercomment.php?action=edit&amp;cid={$row['id']}>Edit</a>]" : "") . ($userid == $CURUSER["id"] || get_user_class() >= UC_MODERATOR ? "- [<a href=usercomment.php?action=delete&amp;cid={$row['id']}>Delete</a>]" : "") . ($row["editedby"] && get_user_class() >= UC_MODERATOR ? "- [<a href=usercomment.php?action=vieworiginal&amp;cid={$row['id']}>View original</a>]" : "") . "</p>\n";
        $avatar = $CURUSER["avatars"] == "yes" ? safeChar($row["avatar"]) : "";
        $text = format_comment($row["text"]);
        if ($row["editedby"]) {
            $text .= "<p><font size=1 class=small>Last edited by <a href=userdetails.php?id={$row['editedby']}><b>{$row['username']}</b></a> at {$row['editedat']} GMT</font></p>\n";
        }
        begin_table(true);
        echo "<tr valign=top>\n";
        echo "<td align=center width=150 style='padding: 0px'><img width=150 src=\"{$avatar}\"></td>\n";
        echo "<td class=text>{$text}</td>\n";
        echo "</tr>\n";
        end_table();
    }
    end_frame();
    end_main_frame();
}
开发者ID:ZenoX2012,项目名称:CyBerFuN-CoDeX,代码行数:35,代码来源:userdetails.php


示例5: insert_badwords_frame

function insert_badwords_frame()
{
    global $badwords, $BASEURL;
    begin_frame("Badwords", true);
    print "<center>";
    begin_table(false, 5);
    print "<tr>";
    for ($I = 0; $I < 3; $I++) {
        if ($I > 0) {
            print "<td class=\"tablecat\"> </td>";
        }
        print "<td class=\"tablecat\">Eingeben...</td><td class=\"tablecat\">...für Schlimmes Wort</td>";
    }
    print "</tr>\n";
    $I = 0;
    print "<tr>";
    while (list($code, $url) = each($badwords)) {
        if ($I && $I % 3 == 0) {
            print "</tr>\n<tr>";
        }
        if ($I % 3) {
            print "<td class=\"inposttable\"> </td>";
        }
        print "<td class=\"tablea\">{$code}</td><td class=\"tableb\">{$url}</td>";
        $I++;
    }
    if ($I % 3) {
        print "<td class=\"inposttable\" colspan=" . (3 - $I % 3) * 3 . "> </td>";
    }
    print "</tr>\n";
    end_table();
    print "</center>";
    end_frame();
}
开发者ID:ZenoX2012,项目名称:CyBerFuN-CoDeX,代码行数:34,代码来源:template.php


示例6: insert_smilies_frame

function insert_smilies_frame()
{
    global $smilies, $BASEURL;
    begin_frame("Smilies", true);
    begin_table(false, 5);
    print "<tr><td class=colhead>Type...</td><td class=colhead>To make a...</td></tr>\n";
    while (list($code, $url) = each($smilies)) {
        print "<tr><td>{$code}</td><td><img src={$BASEURL}/pic/smilies/{$url}></td>\n";
    }
    end_table();
    end_frame();
}
开发者ID:ZenoX2012,项目名称:CyBerFuN-CoDeX,代码行数:12,代码来源:template.php


示例7: insert_smilies_frame

function insert_smilies_frame()
{
    global $smilies, $BASEURL, $pic_base_url;
    begin_frame("Smilies", true);
    begin_table(false, 5);
    print "<tr><td class='colhead'>Type...</td><td class='colhead'>To make a...</td></tr>\n";
    while (list($code, $url) = each($smilies)) {
        print "<tr><td>{$code}</td><td><img src=\"{$pic_base_url}smilies/{$url}\" alt='' /></td></tr>\n";
    }
    end_table();
    end_frame();
}
开发者ID:CtrlSystem,项目名称:biotorrents,代码行数:12,代码来源:html_functions.php


示例8: insert_smilies_frame

function insert_smilies_frame()
{
    global $smilies, $DEFAULTBASEURL;
    begin_frame("Смайлы", true);
    begin_table(false, 5);
    print "<tr><td class=\"colhead\">Написание</td><td class=\"colhead\">Смайл</td></tr>\n";
    while (list($code, $url) = each($smilies)) {
        print "<tr><td>{$code}</td><td><img src=\"{$DEFAULTBASEURL}/pic/smilies/{$url}\"></td>\n";
    }
    end_table();
    end_frame();
}
开发者ID:klldll,项目名称:tbdev,代码行数:12,代码来源:template.php


示例9: insert_smilies_frame

function insert_smilies_frame()
{
    global $smilies, $INSTALLER09;
    $htmlout = '';
    $htmlout .= begin_frame("Smilies", true);
    $htmlout .= begin_table(false, 5);
    $htmlout .= "<tr><td class='colhead'>Type...</td><td class='colhead'>To make a...</td></tr>\n";
    foreach ($smilies as $code => $url) {
        $htmlout .= "<tr><td>{$code}</td><td><img src=\"{$INSTALLER09['pic_base_url']}smilies/{$url}\" alt='' /></td></tr>\n";
    }
    $htmlout .= end_table();
    $htmlout .= end_frame();
    return $htmlout;
}
开发者ID:CharlieHD,项目名称:U-232-V3,代码行数:14,代码来源:html_functions.php


示例10: print_edit

/**
* Prints out the display/edit UI to add/remove groups for this user
* @param string $memberid id of the member to to change groups for
*/
function print_edit($edit, &$user)
{
    $group = new Group(new GroupDB());
    $non_user_groups = $group->getGroups($user->get_id());
    $user_groups = $user->groups;
    begin_table($user->get_name());
    if ($edit) {
        print_groups_to_add($non_user_groups);
        print_move_buttons();
        print_groups_to_remove($user_groups);
        print_save_button($user->get_id());
    } else {
        print_groups_to_view($user_groups);
    }
    end_table();
}
开发者ID:razagilani,项目名称:srrs,代码行数:20,代码来源:group_edit.php


示例11: reqcommenttable

function reqcommenttable($rows)
{
	global $CURUSER, $HTTP_SERVER_VARS;
	begin_main_frame();
	begin_frame();
	$count = 0;

	foreach ($rows as $row) {
		print("<p class=sub>#" . $row["id"] . " bY: ");
		if (isset($row["username"])) {
			$username = $row["username"];
			$ratres = mysql_query("SELECT uploaded, downloaded FROM users WHERE username='$username'");
			$rat = mysql_fetch_array($ratres);
			if ($rat["downloaded"] > 0) {
				$ratio = $rat['uploaded'] / $rat['downloaded'];
				$ratio = number_format($ratio, 3);
				$color = get_ratio_color($ratio);
				if ($color)
					$ratio = "<font color=$color>$ratio</font>";
			} else
				if ($rat["uploaded"] > 0)
					$ratio = "Inf.";
				else
					$ratio = "---";

			$title = $row["title"];
			if ($title == "")
				$title = get_user_class_name($row["class"]);
			else
				$title = htmlspecialchars($title);
			print("<a name=comm".$row["id"]." href=userdetails.php?id=".$row["user"]."><b>".htmlspecialchars($row["username"])."</b></a>".($row["donor"] == "yes" ? "<img src=pic/star.gif alt='Donor'>" : "").($row["warned"] == "yes" ? "<img src="."/pic/warned.gif alt=\"Warned\">" : "")." ($title) (Ratio: $ratio)\n");
		} else
			print("<a name=\"comm" . $row["id"] . "\"><i>(orphaned)</i></a>\n");
		print(" at " . $row["added"] . " GMT" .($row["user"] == $CURUSER["id"] || get_user_class() >= UC_MODERATOR ? "- [<a href=reqcomment.php?action=edit&amp;cid=$row[id]>Edit</a>]" : "") .(get_user_class() >= UC_MODERATOR ? "- [<a href=reqcomment.php?action=delete&amp;cid=$row[id]>Delete</a>]" : "") . "</p>\n");$avatar = ($CURUSER["avatars"] == "yes" ? htmlspecialchars($row["avatar"]) : "");
		if (!$avatar)
			$avatar = "/pic/default_avatar.gif";
		$text = format_comment($row["text"]);
		begin_table(true);
		print("<tr valign=top>\n");
		print("<td align=center width=150 style='padding: 0px'><img width=150 src=$avatar></td>\n");
		print("<td class=text>$text</td>\n");
		print("</tr>\n");
		end_table();
	}
	end_frame();
	end_main_frame();
}
开发者ID:herrag33k,项目名称:TomTorrent,代码行数:47,代码来源:reqdetails.php


示例12: usercommenttable

function usercommenttable($rows)
{
    $htmlout = '';
    global $CURUSER, $INSTALLER09, $userid;
    $htmlout .= begin_main_frame();
    $htmlout .= begin_frame();
    $count = 0;
    foreach ($rows as $row) {
        $htmlout .= "<p class='sub'>#{$row['id']} by ";
        if (isset($row["username"])) {
            $title = $row["title"];
            if ($title == "") {
                $title = get_user_class_name($row["class"]);
            } else {
                $title = htmlsafechars($title);
            }
            $htmlout .= "<a name='comm" . (int) $row['id'] . "' href='userdetails.php?id=" . (int) $row['user'] . "'><b>" . htmlsafechars($row["username"]) . "</b></a>" . ($row["donor"] == "yes" ? "<img src=\"{$INSTALLER09['pic_base_url']}star.gif\" alt='Donor' />" : "") . ($row["warned"] >= 1 ? "<img src=" . "\"{$INSTALLER09['pic_base_url']}warned.gif\" alt=\"Warned\" />" : "") . " ({$title})\n";
        } else {
            $htmlout .= "<a name=\"comm" . (int) $row["id"] . "\"><i>(orphaned)</i></a>\n";
        }
        $htmlout .= " " . get_date($row["added"], 'DATE', 0, 1) . "" . ($userid == $CURUSER["id"] || $row["user"] == $CURUSER["id"] || $CURUSER['class'] >= UC_STAFF ? " - [<a href='usercomment.php?action=edit&amp;cid={$row['id']}'>Edit</a>]" : "") . ($userid == $CURUSER["id"] || $CURUSER['class'] >= UC_STAFF ? " - [<a href='usercomment.php?action=delete&amp;cid=" . (int) $row['id'] . "'>Delete</a>]" : "") . ($row["editedby"] && $CURUSER['class'] >= UC_STAFF ? " - [<a href='usercomment.php?action=vieworiginal&amp;cid=" . (int) $row['id'] . "'>View original</a>]" : "") . "</p>\n";
        $avatar = $CURUSER["avatars"] == "yes" ? htmlsafechars($row["avatar"]) : "";
        if (!$avatar) {
            $avatar = "{$INSTALLER09['pic_base_url']}default_avatar.gif";
        }
        $text = format_comment($row["text"]);
        if ($row["editedby"]) {
            $text .= "<font size='1' class='small'><br /><br />Last edited by <a href='userdetails.php?id=" . (int) $row['editedby'] . "'><b>" . htmlsafechars($row['username']) . "</b></a> " . get_date($row['editedat'], 'DATE', 0, 1) . "</font>\n";
        }
        $htmlout .= begin_table(true);
        $htmlout .= "<tr valign='top'>\n";
        $htmlout .= "<td align='center' width='150' style='padding:0px'><img width='150' src=\"{$avatar}\" alt=\"Avatar\" /></td>\n";
        $htmlout .= "<td class='text'>{$text}</td>\n";
        $htmlout .= "</tr>\n";
        $htmlout .= end_table();
    }
    $htmlout .= end_frame();
    $htmlout .= end_main_frame();
    return $htmlout;
}
开发者ID:CharlieHD,项目名称:U-232-V3,代码行数:40,代码来源:usercomment.php


示例13: _torrenttable

function _torrenttable($res, $frame_caption, $speed = "false")
{
    global $db;
    block_begin($frame_caption, 'center');
    begin_table();
    $num = 0;
    while ($a = $res->fetch_assoc()) {
        ++$num;
        if ($a["leechers"] > 0) {
            $r = (int) $a["seeds"] / (int) $a["leechers"];
            $ratio = number_format($r, 2);
        } else {
            $ratio = INFINITE;
        }
        if (!isset($menu)) {
            $menu = "";
        }
        if ($menu != "1") {
            echo "<tr>" . "<table width='100%' class='lista'>" . "<td class='header' align='center'>" . USER_LEVEL . "</td>" . "<td class='header'>" . FILE . "</td>";
            if ($speed != "true") {
                echo "<td class='header' align='center'>" . FINISHED . "</td>" . "<td class='header' align='center'>" . SEEDERS . "</td>" . "<td class='header' align='center'>" . LEECHERS . "</td>" . "<td class='header' align='center'>" . PEERS . "</td>" . "<td class='header' align='center'>" . RATIO . "</td>";
            } else {
                echo "<td class='header' align='right'>" . SPEED . "</td>";
            }
            echo "</tr>";
            $menu = 1;
        }
        print "<tr><td class='lista' align='center'>" . $num . "</td><td class='lista' align='left'>";
        print "<a href='" . "details.php?id=" . $a['hash'] . "'>" . "<b>";
        print security::html_safe($a["name"]) . "</b></a></td>";
        if ($speed != "true") {
            print "<td class='lista' align='center' width='10%' ><a href='torrent_history.php?id=" . $a["hash"] . "'>" . number_format((int) $a["finished"]) . "</a></td><td class='lista' align='center' width='10%' ><a href='peers.php?id=" . $a["hash"] . "'>" . number_format((int) $a["seeds"]) . "</a></td><td class='lista' align='center' width='10%' > <a href='peers.php?id=" . $a["hash"] . "'>" . number_format((int) $a["leechers"]) . "</a></td><td class='lista' align='center' width='10%' > <a href='peers.php?id=" . $a["hash"] . "'>" . number_format((int) $a["leechers"] + (int) $a["seeds"]) . "</a></td><td class='lista' align='center' width='10%'>" . $ratio . "</td>\n";
        } else {
            print "<td class='lista' align='center'>" . misc::makesize((int) $a["speed"]) . "/s" . "\n";
        }
    }
    end_table();
    block_end();
}
开发者ID:HDVinnie,项目名称:BtiTracker-1.5.0,代码行数:39,代码来源:extra-stats.php


示例14: dbconn

// | along with TBDevYSE; if not, write to the Free Software Foundation,      |
// | Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA            |
// +--------------------------------------------------------------------------+
// |                                               Do not remove above lines! |
// +--------------------------------------------------------------------------+
*/
require "include/bittorrent.php";
dbconn();
loggedinorreturn();
if (get_user_class() < UC_MODERATOR) {
    stderr($tracker_lang['error'], "Отказано в доступе.");
}
stdhead("Предупрежденные пользователи");
$warned = number_format(get_row_count("users", "WHERE warned='yes'"));
begin_frame("Предупрежденные пользователи: ({$warned})", true);
begin_table();
$res = sql_query("SELECT * FROM users WHERE warned=1 AND enabled='yes' ORDER BY (users.uploaded/users.downloaded)") or sqlerr(__FILE__, __LINE__);
$num = mysql_num_rows($res);
print "<table border=1 width=675 cellspacing=0 cellpadding=2><form action=\"nowarn.php\" method=post>\n";
print "<tr align=center><td class=colhead width=90>Пользователь</td>\n<td class=colhead width=70>Зарегистрирован</td>\n<td class=colhead width=75>Последний&nbsp;раз&nbsp;был&nbsp;на&nbsp;трекере</td>\n<td class=colhead width=75>Класс</td>\n<td class=colhead width=70>Закачал</td>\n<td class=colhead width=70>Раздал</td>\n<td class=colhead width=45>Рейтинг</td>\n<td class=colhead width=125>Окончание</td>\n<td class=colhead width=65>Убрать</td>\n<td class=colhead width=65>Отключить</td></tr>\n";
for ($i = 1; $i <= $num; $i++) {
    $arr = mysql_fetch_assoc($res);
    if ($arr['added'] == '0000-00-00 00:00:00') {
        $arr['added'] = '-';
    }
    if ($arr['last_access'] == '0000-00-00 00:00:00') {
        $arr['last_access'] = '-';
    }
    if ($arr["downloaded"] != 0) {
        $ratio = number_format($arr["uploaded"] / $arr["downloaded"], 3);
    } else {
开发者ID:klldll,项目名称:tbdev,代码行数:31,代码来源:warned.php


示例15: commenttable

function commenttable($rows, $variant = 'torrent')
{
    require_once INCL_DIR . 'html_functions.php';
    global $CURUSER, $TBDEV;
    $lang = load_language('torrenttable_functions');
    $htmlout = '';
    $count = 0;
    $variant_options = array('torrent' => 'details', 'request' => 'viewrequests');
    if (isset($variant_options[$variant])) {
        $locale_link = $variant_options[$variant];
    } else {
        return;
    }
    $extra_link = $variant == 'request' ? '&type=request' : '';
    $htmlout .= begin_main_frame();
    $htmlout .= begin_frame();
    foreach ($rows as $row) {
        $htmlout .= "<p class='sub'>#{$row["id"]} {$lang["commenttable_by"]} ";
        if (isset($row["username"])) {
            if ($row['anonymous'] == 'yes') {
                $htmlout .= ($CURUSER['class'] >= UC_MODERATOR ? 'Anonymous - 
                Posted by: <b>' . htmlspecialchars($row['username']) . '</b> 
                ID: ' . $row['user'] . '' : 'Anonymous') . ' ';
            } else {
                $title = $row["title"];
                if ($title == "") {
                    $title = get_user_class_name($row["class"]);
                } else {
                    $title = htmlspecialchars($title);
                }
                $htmlout .= "<a name='comm{$row["id"]}' href='userdetails.php?id={$row["user"]}'><b>" . htmlspecialchars($row["username"]) . "</b></a>" . ($row["donor"] == "yes" ? "<img src='{$TBDEV['pic_base_url']}star.gif' alt='" . $lang["commenttable_donor_alt"] . "' />" : "") . ($row["warned"] == "yes" ? "<img src=" . "'{$TBDEV['pic_base_url']}warned.gif' alt='" . $lang["commenttable_warned_alt"] . "' />" : "") . " ({$title})\n";
            }
        } else {
            $htmlout .= "<a name='comm{$row["id"]}'><i>(" . $lang["commenttable_orphaned"] . ")</i></a>\n";
        }
        $htmlout .= get_date($row['added'], '');
        $htmlout .= ($row["user"] == $CURUSER["id"] || $CURUSER["class"] >= UC_STAFF ? "- [<a href='comment.php?action=edit&amp;cid=" . $row['id'] . $extra_link . "&amp;tid=" . $row[$variant] . "'>" . $lang["commenttable_edit"] . "</a>]" : "") . ($CURUSER["class"] >= UC_VIP ? " - [<a href='report.php?type=Comment&amp;id=" . $row['id'] . "'>Report this Comment</a>]" : "") . ($CURUSER["class"] >= UC_STAFF ? " - [<a href='comment.php?action=delete&amp;cid=" . $row['id'] . $extra_link . "&amp;tid=" . $row[$variant] . "'>" . $lang["commenttable_delete"] . "</a>]" : "") . ($row["editedby"] && $CURUSER["class"] >= UC_STAFF ? "- [<a href='comment.php?action=vieworiginal&amp;cid=" . $row['id'] . $extra_link . "&amp;tid=" . $row[$variant] . "'>" . $lang["commenttable_view_original"] . "</a>]" : "") . "</p>\n";
        $avatar = $CURUSER["avatars"] == "all" ? htmlspecialchars($row["avatar"]) : ($CURUSER["avatars"] == "some" && $row["offavatar"] == "no" ? htmlspecialchars($row["avatar"]) : "");
        if (!$avatar) {
            $avatar = "{$TBDEV['pic_base_url']}forumicons/default_avatar.gif";
        }
        $text = format_comment($row["text"]);
        if ($row["editedby"]) {
            $text .= "<p><font size='1' class='small'>" . $lang["commenttable_last_edited_by"] . " <a href='userdetails.php?id={$row['editedby']}'><b>{$row['username']}</b></a> " . $lang["commenttable_last_edited_at"] . " " . get_date($row['editedat'], 'DATE') . "</font></p>\n";
        }
        $htmlout .= begin_table(true);
        $htmlout .= "<tr valign='top'>\n";
        $htmlout .= "<td align='center' width='150' style='padding: 0px'><img width='{$row['av_w']}' height='{$row['av_h']}' src='{$avatar}' alt='' /><br />" . get_reputation($row, 'comments') . "</td>\n";
        $htmlout .= "<td class='text'>{$text}</td>\n";
        $htmlout .= "</tr>\n";
        $htmlout .= end_table();
    }
    $htmlout .= end_frame();
    $htmlout .= end_main_frame();
    return $htmlout;
}
开发者ID:thefkboss,项目名称:U-232,代码行数:56,代码来源:torrenttable_functions.php


示例16: stderr

if ($CURUSER['class'] >= MAX_CLASS || isMod($forumid, "forum")) {
    if (!is_valid_id($forumid)) {
        stderr('Error', 'Invalid ID!');
    }
    $res = sql_query("SELECT name, description, min_class_read, min_class_write, min_class_create FROM forums WHERE id=" . sqlesc($forumid)) or sqlerr(__FILE__, __LINE__);
    if (mysqli_num_rows($res) == 0) {
        stderr('Error', 'No forum found with that ID!');
    }
    $forum = mysqli_fetch_assoc($res);
    if ($INSTALLER09['forums_online'] == 0) {
        $HTMLOUT .= stdmsg('Warning', 'Forums are currently in maintainance mode');
    }
    $HTMLOUT .= begin_main_frame();
    $HTMLOUT .= begin_frame("Edit Forum", "center");
    $HTMLOUT .= "<form method='post' action='{$INSTALLER09['baseurl']}/forums.php?action=updateforum&amp;forumid={$forumid}'>\n";
    $HTMLOUT .= begin_table();
    $HTMLOUT .= "<tr><td class='rowhead'>Forum name</td>\r\n        <td align='left' style='padding: 0px'><input type='text' size='60' maxlength='{$Multi_forum['configs']['maxsubjectlength']}' name='name' style='border: 0px; height: 19px' value=\"" . htmlsafechars($forum['name']) . "\" /></td></tr>\r\n        <tr><td class='rowhead'>Description</td><td align='left' style='padding: 0px'><textarea name='description' cols='68' rows='3' style='border: 0px'>" . htmlsafechars($forum['description']) . "</textarea></td></tr>\r\n        <tr><td class='rowhead'></td><td align='left' style='padding: 0px'>&nbsp;Minimum <select name='readclass'>";
    for ($i = 0; $i <= MAX_CLASS; ++$i) {
        $HTMLOUT .= "<option value='{$i}' " . ($i == $forum['min_class_read'] ? " selected='selected'" : "") . ">" . get_user_class_name($i) . "</option>\n";
    }
    $HTMLOUT .= "</select> Class required to View<br />\n&nbsp;Minimum <select name='writeclass'>";
    for ($i = 0; $i <= MAX_CLASS; ++$i) {
        $HTMLOUT .= "<option value='{$i}' " . ($i == $forum['min_class_write'] ? " selected='selected'" : "") . ">" . get_user_class_name($i) . "</option>\n";
    }
    $HTMLOUT .= "</select> Class required to Post<br />\n&nbsp;Minimum <select name='createclass'>";
    for ($i = 0; $i <= MAX_CLASS; ++$i) {
        $HTMLOUT .= "<option value='{$i}' " . ($i == $forum['min_class_create'] ? " selected='selected'" : "") . ">" . get_user_class_name($i) . "</option>\n";
    }
    $HTMLOUT .= "</select> Class required to Create Topics</td></tr>\r\n        <tr><td colspan='2' align='center'><input type='submit' value='Submit' /></td></tr>\n";
    $HTMLOUT .= end_table();
    $HTMLOUT .= "</form>";
开发者ID:Bigjoos,项目名称:U-232-V5,代码行数:31,代码来源:edit.php


示例17: begin_table

        $class = "clearalt7";
    } else {
        $count2 = 0;
        $class = "clearalt6";
    }
    // =======end
    print "<p class=sub><table border=0 cellspacing=0 cellpadding=0 width=737><tr><td class=colhead width=737>\r\n" . ($newposts ? " <b><font color=red>NEW REPLY!</font></b>" : "") . "<br><b>Forum: </b>\r\n<a class=altlink href=/forums.php?action=viewforum&forumid={$forumid}>{$forumname}</a>\r\n<b>Topic: </b>\r\n<a class=altlink href=/forums.php?action=viewtopic&topicid={$topicid}>{$topicname}</a>\r\n<b>Post: </b>\r\n#<a class=altlink href=/forums.php?action=viewtopic&topicid={$topicid}&page=p{$postid}#{$postid}>{$postid}</a><br>\r\n<b>Last Post By:</b> <a class=altlink href=userdetails.php?id={$posterid}><b>{$res3['username']}</a> added:</b> {$added} </td>\r\n<td class=colhead2 align=right width=20%>";
    // === delete subscription
    if ($_GET[check] == "yes") {
        echo "<INPUT type=checkbox checked name=deletesubscription[] id=deletesubscription value={$topicid}> ";
    } else {
        echo "<INPUT type=checkbox name=deletesubscription[] id=deletesubscription value={$topicid}> ";
    }
    // === end
    print "<b>un-subscribe</b></td></tr></table></p>\n";
    begin_table(true);
    $body = format_comment($arr2["body"]);
    if (is_valid_id($arr['editedby'])) {
        $subres = sql_query("SELECT username FROM users WHERE id={$arr['editedby']}");
        if (mysql_num_rows($subres) == 1) {
            $subrow = mysql_fetch_assoc($subres);
            $body .= "<p><font size=1 class=small>Last edited by <a href=userdetails.php?id={$arr['editedby']}><b>{$subrow['username']}</b></a> at {$arr['editedat']} GMT</font></p>\n";
        }
    }
    // print("<tr valign=top><td class=$class>" . CutName($body, 300) . "</td></tr>\n");
    print "<tr valign=top><td class={$class}>{$body}</td></tr>\n";
    // use this line if you don't want to cut the post
    end_table();
}
?>
<br><table width=737><tr><td align=right class=colhead><h1></h1>
开发者ID:ZenoX2012,项目名称:CyBerFuN-CoDeX,代码行数:31,代码来源:subscriptions.php


示例18: peerstable

function peerstable($res, $frame_caption)
{
    global $lang;
    $htmlout = '';
    $htmlout .= begin_frame($frame_caption, true);
    $htmlout .= begin_table();
    $htmlout .= "<tr><td class='colhead'>{$lang['common_rank']}</td><td class='colhead'>{$lang['peers_uname']}</td><td class='colhead'>{$lang['peers_ulrate']}</td><td class='colhead'>{$lang['peers_dlrate']}</td></tr>";
    $n = 1;
    while ($arr = mysql_fetch_assoc($res)) {
        $highlight = $CURUSER["id"] == $arr["userid"] ? " bgcolor='#BBAF9B'" : "";
        $htmlout .= "<tr><td{$highlight}>{$n}</td><td{$highlight}><a href='userdetails.php?id=" . $arr["userid"] . "'><b>" . $arr["username"] . "</b></a></td><td{$highlight}>" . mksize($arr["uprate"]) . "/s</td><td{$highlight}>" . mksize($arr["downrate"]) . "/s</td></tr>\n";
        ++$n;
    }
    $htmlout .= end_table();
    $htmlout .= end_frame();
    return $htmlout;
}
开发者ID:thefkboss,项目名称:U-232,代码行数:17,代码来源:topten.php


示例19: offcommenttable

function offcommenttable($rows)
{
    global $CURUSER, $HTTP_SERVER_VARS;
    begin_main_frame();
    begin_frame();
    $count = 0;
    $count2 = '';
    $id = '';
    foreach ($rows as $row) {
        // =======change colors
        if ($count2 == 0) {
            $count2 = $count2 + 1;
            $class = "clearalt6";
        } else {
            $count2 = 0;
            $class = "clearalt7";
        }
        print "<br>";
        begin_table(true);
        print "<tr><td class=colhead colspan=2><p class=sub><a name=comment_" . $row["id"] . ">#" . $row["id"] . "</a> by: ";
        if (isset($row["username"])) {
            $username = $row["username"];
            $ratres = sql_query("SELECT uploaded, downloaded from users where username='{$username}'");
            $rat = mysql_fetch_array($ratres);
            if ($rat["downloaded"] > 0) {
                $ratio = $rat['uploaded'] / $rat['downloaded'];
                $ratio = number_format($ratio, 3);
                $color = get_ratio_color($ratio);
                if ($color) {
                    $ratio = "<font color={$color}>{$ratio}</font>";
                }
            } else {
                if ($rat["uploaded"] > 0) {
                    $ratio = &quo 

鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP begin_transaction函数代码示例发布时间:2022-05-24
下一篇:
PHP begin_sql函数代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap