本文整理汇总了PHP中format_comment函数的典型用法代码示例。如果您正苦于以下问题:PHP format_comment函数的具体用法?PHP format_comment怎么用?PHP format_comment使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了format_comment函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: 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&cid={$row['id']}>Edit</a>]" : "") . ($userid == $CURUSER["id"] || get_user_class() >= UC_MODERATOR ? "- [<a href=usercomment.php?action=delete&cid={$row['id']}>Delete</a>]" : "") . ($row["editedby"] && get_user_class() >= UC_MODERATOR ? "- [<a href=usercomment.php?action=vieworiginal&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
示例2: commenttable
function commenttable($rows, $redaktor = "comment")
{
global $CURUSER, $avatar_max_width;
$count = 0;
foreach ($rows as $row) {
if ($row["downloaded"] > 0) {
$ratio = $row['uploaded'] / $row['downloaded'];
$ratio = number_format($ratio, 2);
} elseif ($row["uploaded"] > 0) {
$ratio = "Inf.";
} else {
$ratio = "---";
}
if (strtotime($row["last_access"]) > gmtime() - 600) {
$online = "online";
$online_text = "В сети";
} else {
$online = "offline";
$online_text = "Не в сети";
}
print "<table class=maibaugrand width=100% border=1 cellspacing=0 cellpadding=3>";
print "<tr><td class=colhead align=\"left\" colspan=\"2\" height=\"24\">";
if (isset($row["username"])) {
$title = $row["title"];
if ($title == "") {
$title = get_user_class_name($row["class"]);
} else {
$title = htmlspecialchars_uni($title);
}
print ":: <img src=\"pic/buttons/button_" . $online . ".gif\" alt=\"" . $online_text . "\" title=\"" . $online_text . "\" style=\"position: relative; top: 2px;\" border=\"0\" height=\"14\">" . " <a name=comm" . $row["id"] . " href=userdetails.php?id=" . $row["user"] . " class=altlink_white><b>" . get_user_class_color($row["class"], htmlspecialchars_uni($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} ::\n" . " <img src=\"pic/upl.gif\" alt=\"upload\" border=\"0\" width=\"12\" height=\"12\"> " . mksize($row["uploaded"]) . " :: <img src=\"pic/down.gif\" alt=\"download\" border=\"0\" width=\"12\" height=\"12\"> " . mksize($row["downloaded"]) . " :: <font color=\"" . get_ratio_color($ratio) . "\">{$ratio}</font> :: ";
} else {
print "<a name=\"comm" . $row["id"] . "\"><i>[Anonymous]</i></a>\n";
}
$avatar = $CURUSER["avatars"] == "yes" ? htmlspecialchars_uni($row["avatar"]) : "";
if (!$avatar) {
$avatar = "pic/default_avatar.gif";
}
if (md5($row['text']) == $row['text_hash']) {
$text = $row['text_parsed'];
} else {
$text = format_comment($row['text']);
sql_query('INSERT INTO comments_parsed (cid, text_hash, text_parsed) VALUES (' . implode(', ', array_map('sqlesc', array($row['id'], md5($row['text']), $text))) . ')') or sqlerr(__FILE__, __LINE__);
}
if ($row["editedby"]) {
//$res = mysql_fetch_assoc(sql_query("SELECT * FROM users WHERE id = $row[editedby]")) or sqlerr(__FILE__,__LINE__);
$text .= "<p><font size=1 class=small>Последний раз редактировалось <a href=userdetails.php?id={$row['editedby']}><b>{$row['editedbyname']}</b></a> в {$row['editedat']}</font></p>\n";
}
print "</td></tr>";
print "<tr valign=top>\n";
print "<td style=\"padding: 0px; width: 5%;\" align=\"center\"><img src={$avatar} width=\"{$avatar_max_width}\"> </td>\n";
print "<td width=100% class=text>";
//print("<span style=\"float: right\"><a href=\"#top\"><img title=\"Top\" src=\"pic/top.gif\" alt=\"Top\" border=\"0\" width=\"15\" height=\"13\"></a></span>");
print "{$text}</td>\n";
print "</tr>\n";
print "<tr><td class=colhead align=\"center\" colspan=\"2\">";
print "<div style=\"float: left; width: auto;\">" . ($CURUSER ? " [<a href=\"" . $redaktor . ".php?action=quote&cid={$row['id']}\" class=\"altlink_white\">Цитата</a>]" : "") . ($row["user"] == $CURUSER["id"] || get_user_class() >= UC_MODERATOR ? " [<a href=" . $redaktor . ".php?action=edit&cid={$row['id']} class=\"altlink_white\">Изменить</a>]" : "") . (get_user_class() >= UC_MODERATOR ? " [<a href=\"" . $redaktor . ".php?action=delete&cid={$row['id']}\" class=\"altlink_white\">Удалить</a>]" : "") . ($row["editedby"] && get_user_class() >= UC_MODERATOR ? " [<a href=\"" . $redaktor . ".php?action=vieworiginal&cid={$row['id']}\" class=\"altlink_white\">Оригинал</a>]" : "") . (get_user_class() >= UC_MODERATOR ? " IP: " . ($row["ip"] ? "<a href=\"usersearch.php?ip={$row['ip']}\" class=\"altlink_white\">" . $row["ip"] . "</a>" : "Неизвестен") : "") . "</div>";
print "<div align=\"right\"><!--<font size=1 class=small>-->Комментарий добавлен: " . $row["added"] . " GMT<!--</font>--></td></tr>";
print "</table><br>";
}
}
开发者ID:klldll,项目名称:tbdev,代码行数:60,代码来源:functions_commenttable.php
示例3: 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
示例4: autoshout
function autoshout($msg)
{
global $INSTALLER09, $mc1;
require_once INCL_DIR . 'bbcode_functions.php';
sql_query('INSERT INTO shoutbox(userid,date,text,text_parsed,autoshout)VALUES (' . $INSTALLER09['bot_id'] . ',' . TIME_NOW . ',' . sqlesc($msg) . ',' . sqlesc(format_comment($msg)) . ', "yes")');
$mc1->delete_value('auto_shoutbox_');
}
开发者ID:Bigjoos,项目名称:U-232-V5,代码行数:7,代码来源:user_functions.php
示例5: insert_tag
function insert_tag($name, $description, $syntax, $example, $remarks)
{
$result = format_comment($example);
echo '<p class="sub"><b>'.$name.'</b></p>'."\n";
echo '<table class="main" width="100%" border="1" cellspacing="0" cellpadding="5">'."\n";
echo '<tr valign="top"><td width="25%">Lýsing:</td><td>'.$description."\n";
echo '<tr valign="top"><td>Kóði:</td><td><tt>'.$syntax.'</tt>'."\n";
echo '<tr valign="top"><td>Dæmi:</td><td><tt>'.$example.'</tt>'."\n";
echo '<tr valign="top"><td>Úr því kemur:</td><td>'.$result."\n";
if ($remarks != '')
echo '<tr><td>Athugasemdir:</td><td>'.$remarks."\n";
echo '</table>'."\n";
}
开发者ID:herrag33k,项目名称:TomTorrent,代码行数:13,代码来源:tags.php
示例6: insert_tag
function insert_tag($name, $description, $syntax, $example, $remarks)
{
$result = format_comment($example);
print "<p><b>{$name}</b></p>\n";
print "<table width='100%' border='1' cellspacing='0' cellpadding='3'>\n";
print "<tr valign='top'><td width='25%'>" . T_("DESCRIPTION") . ":</td><td>{$description}</td></tr>\n";
print "<tr valign='top'><td>" . T_("SYNTAX") . ":</td><td><span class='teletype'>{$syntax}</span></td></tr>\n";
print "<tr valign='top'><td>" . T_("EXAMPLE") . ":</td><td><span class='teletype'>{$example}</span></td></tr>\n";
print "<tr valign='top'><td>" . T_("RESULT") . ":</td><td>{$result}</td></tr>\n";
if ($remarks != "") {
print "<tr><td>" . T_("REMARKS") . ":</td><td>{$remarks}</td></tr>\n";
}
print "</table>\n";
}
开发者ID:lavanoid,项目名称:TorrentTrader3,代码行数:14,代码来源:tags.php
示例7: insert_tag
function insert_tag($name, $description, $syntax, $example, $remarks)
{
$result = format_comment($example);
print "<p class=sub><b>{$name}</b></p>\n";
print "<table class=main width=100% border=1 cellspacing=0 cellpadding=5>\n";
print "<tr valign=top><td width=25%>Описание:</td><td>{$description}\n";
print "<tr valign=top><td>Синтаксис:</td><td><tt>{$syntax}</tt>\n";
print "<tr valign=top><td>Пример:</td><td><tt>{$example}</tt>\n";
print "<tr valign=top><td>Результат:</td><td>{$result}\n";
if ($remarks != "") {
print "<tr><td>Примечание:</td><td>{$remarks}\n";
}
print "</table>\n";
}
开发者ID:klldll,项目名称:tbdev,代码行数:14,代码来源:tags.php
示例8: insert_tag
function insert_tag($name, $description, $syntax, $example, $remarks)
{
$result = format_comment($example);
print "<div class='sub'><b>{$name}</b></div>\n";
print "<table class='main' width='100%' border='1' cellspacing='0' cellpadding='5'>\n";
print "<tr valign='top'><td width='25%'>Description:</td><td>{$description}</td></tr>\n";
print "<tr valign='top'><td>Syntax:</td><td><tt>{$syntax}</tt></td></tr>\n";
print "<tr valign='top'><td>Example:</td><td><tt>{$example}</tt></td></tr>\n";
print "<tr valign='top'><td>Result:</td><td>{$result}</td></tr>\n";
if ($remarks != "") {
print "<tr><td>Remarks:</td><td>{$remarks}</td></tr>\n";
}
print "</table>\n";
}
开发者ID:CtrlSystem,项目名称:biotorrents,代码行数:14,代码来源:tags.php
示例9: insert_tag
function insert_tag($name, $description, $syntax, $example, $remarks)
{
global $lang_tags;
$result = format_comment($example);
print "<p class=sub><b>{$name}</b></p>\n";
print "<table class=main width=100% border=1 cellspacing=0 cellpadding=5>\n";
print "<tr valign=top><td width=25%>" . $lang_tags['text_description'] . "</td><td>{$description}\n";
print "<tr valign=top><td>" . $lang_tags['text_syntax'] . "</td><td><tt>{$syntax}</tt>\n";
print "<tr valign=top><td>" . $lang_tags['text_example'] . "</td><td><tt>{$example}</tt>\n";
print "<tr valign=top><td>" . $lang_tags['text_result'] . "</td><td>{$result}\n";
if ($remarks != "") {
print "<tr><td>" . $lang_tags['text_remarks'] . "</td><td>{$remarks}\n";
}
print "</table>\n";
}
开发者ID:chenrizhi,项目名称:mtpt,代码行数:15,代码来源:tags.php
示例10: 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&cid=$row[id]>Edit</a>]" : "") .(get_user_class() >= UC_MODERATOR ? "- [<a href=reqcomment.php?action=delete&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
示例11: insert_tag
function insert_tag($name, $description, $syntax, $example, $remarks)
{
global $lang;
$result = format_comment($example);
$htmlout = '';
$htmlout .= "<div class='sub'><b>{$name}</b></div>\n";
$htmlout .= "<table class='main' width='100%' border='1' cellspacing='0' cellpadding='5'>\n";
$htmlout .= "<tr valign='top'><td width='25%'>{$lang['tags_description']}</td><td>{$description}</td></tr>\n";
$htmlout .= "<tr valign='top'><td>{$lang['tags_systax']}</td><td><tt>{$syntax}</tt></td></tr>\n";
$htmlout .= "<tr valign='top'><td>{$lang['tags_example']}</td><td><tt>{$example}</tt></td></tr>\n";
$htmlout .= "<tr valign='top'><td>{$lang['tags_result']}</td><td>{$result}</td></tr>\n";
if ($remarks != "") {
$htmlout .= "<tr><td>{$lang['tags_remarks']}</td><td>{$remarks}</td></tr>\n";
}
$htmlout .= "</table>\n";
return $htmlout;
}
开发者ID:CharlieHD,项目名称:U-232-V2,代码行数:17,代码来源:tags.php
示例12: usercommenttable
function usercommenttable($rows)
{
$htmlout = '';
global $CURUSER, $INSTALLER09, $userid, $lang;
$htmlout .= "<table class='main' width='750' border='0' cellspacing='0' cellpadding='0'>" . "<tr><td class='embedded'>";
$htmlout .= begin_frame();
$count = 0;
foreach ($rows as $row) {
$htmlout .= "<p class='sub'>#" . (int) $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='{$lang['userdetails_donor']}' />" : "") . ($row["warned"] >= "1" ? "<img src=" . "\"{$INSTALLER09['pic_base_url']}warned.gif\" alt=\"{$lang['userdetails_warned']}\" />" : "") . " ({$title})\n";
} else {
$htmlout .= "<a name=\"comm" . (int) $row["id"] . "\"><i>{$lang['userdetails_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&cid=" . (int) $row['id'] . "'>{$lang['userdetails_comm_edit']}</a>]" : "") . ($userid == $CURUSER["id"] || $CURUSER['class'] >= UC_STAFF ? " - [<a href='usercomment.php?action=delete&cid=" . (int) $row['id'] . "'>{$lang['userdetails_comm_delete']}</a>]" : "") . ($row["editedby"] && $CURUSER['class'] >= UC_STAFF ? " - [<a href='usercomment.php?action=vieworiginal&cid=" . (int) $row['id'] . "'>{$lang['userdetails_comm_voriginal']}</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 />{$lang['userdetails_comm_ledited']}<a href='userdetails.php?id=" . (int) $row['editedby'] . "'><b>" . htmlsafechars($row['username']) . "</b></a> " . get_date($row['editedat'], 'DATE', 0, 1) . "</font>\n";
}
$htmlout .= "<table width='100%' border='1' cellspacing='0' cellpadding='5'>";
$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 .= "</table>";
}
$htmlout .= end_frame();
$htmlout .= "</td></tr></table>";
return $htmlout;
}
开发者ID:UniversalAdministrator,项目名称:U-232-V4,代码行数:40,代码来源:usercomments.php
示例13: torrenttable
//.........这里部分代码省略.........
if ($variant == "mytorrents") {
$htmlout .= "<td align='center'><a href='edit.php?id=" . (int) $row['id'] . "amp;returnto=" . urlencode($_SERVER["REQUEST_URI"]) . "'>{$lang["torrenttable_edit"]}</a></td>\n";
}
$htmlout .= $variant == "index" ? "<td align='center'><a href=\"download.php?torrent={$id}" . ($CURUSER['ssluse'] == 3 ? "&ssl=1" : "") . "\"><img src='{$INSTALLER09['pic_base_url']}zip.gif' border='0' alt='Download This Torrent!' title='Download This Torrent!' /></a></td>" : "";
if ($variant == "mytorrents") {
$htmlout .= "<td align='right'>";
if ($row["visible"] == "no") {
$htmlout .= "<b>{$lang["torrenttable_not_visible"]}</b>";
} else {
$htmlout .= "{$lang["torrenttable_visible"]}";
}
$htmlout .= "</td>\n";
}
/** pdq bookmarks **/
$booked = '';
if (!empty($book)) {
foreach ($book as $bk) {
if ($bk['torrentid'] == $id) {
$booked = 1;
}
}
}
$rm_status = !$booked ? ' style="display:none;"' : ' style="display:inline;"';
$bm_status = $booked ? ' style="display:none;"' : ' style="display:inline;"';
$bookmark = '<span id="bookmark' . $id . '"' . $bm_status . '>
<a href="bookmark.php?torrent=' . $id . '&action=add" class="bookmark" name="' . $id . '">
<span title="Bookmark it!" class="add_bookmark_b">
<img src="' . $INSTALLER09['pic_base_url'] . 'aff_tick.gif" align="top" width="14px" alt="Bookmark it!" title="Bookmark it!" />
</span>
</a>
</span>
<span id="remove' . $id . '"' . $rm_status . '>
<a href="bookmark.php?torrent=' . $id . '&action=delete" class="remove" name="' . $id . '">
<span class="remove_bookmark_b">
<img src="' . $INSTALLER09['pic_base_url'] . 'aff_cross.gif" align="top" width="14px" alt="Delete Bookmark!" title="Delete Bookmark!" />
</span>
</a>
</span>';
if ($variant == "index") {
$htmlout .= "<td align='right'>{$bookmark}</td>";
}
if ($row["type"] == "single") {
$htmlout .= "<td align='right'>" . (int) $row["numfiles"] . "</td>\n";
} else {
if ($variant == "index") {
$htmlout .= "<td align='right'><b><a href='filelist.php?id={$id}'>" . (int) $row["numfiles"] . "</a></b></td>\n";
} else {
$htmlout .= "<td align='right'><b><a href='filelist.php?id={$id}'>" . (int) $row["numfiles"] . "</a></b></td>\n";
}
}
if (!$row["comments"]) {
$htmlout .= "<td align='right'>" . (int) $row["comments"] . "</td>\n";
} else {
if ($variant == "index") {
$htmlout .= "<td align='right'><b><a href='details.php?id={$id}&hit=1&tocomm=1'>" . (int) $row["comments"] . "</a></b></td>\n";
} else {
$htmlout .= "<td align='right'><b><a href='details.php?id={$id}&page=0#startcomments'>" . (int) $row["comments"] . "</a></b></td>\n";
}
}
$htmlout .= "<td align='center'><span style='white-space: nowrap;'>" . str_replace(",", "<br />", get_date($row['added'], '')) . "</span></td>\n";
$htmlout .= "<td align='center'>" . str_replace(" ", "<br />", mksize($row["size"])) . "</td>\n";
if ($row["times_completed"] != 1) {
$_s = "" . $lang["torrenttable_time_plural"] . "";
} else {
$_s = "" . $lang["torrenttable_time_singular"] . "";
}
$htmlout .= "<td align='center'><a href='snatches.php?id={$id}'>" . number_format($row["times_completed"]) . "<br />{$_s}</a></td>\n";
if ($row["seeders"]) {
if ($variant == "index") {
if ($row["leechers"]) {
$ratio = $row["seeders"] / $row["leechers"];
} else {
$ratio = 1;
}
$htmlout .= "<td align='right'><b><a href='peerlist.php?id={$id}#seeders'><font color='" . get_slr_color($ratio) . "'>" . (int) $row["seeders"] . "</font></a></b></td>\n";
} else {
$htmlout .= "<td align='right'><b><a class='" . linkcolor($row["seeders"]) . "' href='peerlist.php?id={$id}#seeders'>" . (int) $row["seeders"] . "</a></b></td>\n";
}
} else {
$htmlout .= "<td align='right'><span class='" . linkcolor($row["seeders"]) . "'>" . (int) $row["seeders"] . "</span></td>\n";
}
if ($row["leechers"]) {
if ($variant == "index") {
$htmlout .= "<td align='right'><b><a href='peerlist.php?id={$id}#leechers'>" . number_format($row["leechers"]) . "</a></b></td>\n";
} else {
$htmlout .= "<td align='right'><b><a class='" . linkcolor($row["leechers"]) . "' href='peerlist.php?id={$id}#leechers'>" . (int) $row["leechers"] . "</a></b></td>\n";
}
} else {
$htmlout .= "<td align='right'>0</td>\n";
}
if ($variant == "index") {
$htmlout .= "<td align='center'>" . (isset($row["username"]) ? $row["anonymous"] == "yes" && $CURUSER['class'] < UC_STAFF && $row['owner'] != $CURUSER['id'] ? "<i>" . $lang['torrenttable_anon'] . "</i>" : "<a href='userdetails.php?id=" . (int) $row["owner"] . "'><b>" . htmlsafechars($row["username"]) . "</b></a>" : "<i>(" . $lang["torrenttable_unknown_uploader"] . ")</i>") . "</td>\n";
}
$htmlout .= "</tr>\n";
$htmlout .= "<tr id=\"kdescr" . (int) $row["id"] . "\" style=\"display:none;\"><td width=\"100%\" colspan=\"12\">" . format_comment($descr, false) . "</td></tr>\n";
}
$htmlout .= "</table><!--</div>-->\n";
return $htmlout;
}
开发者ID:CharlieHD,项目名称:U-232-V3,代码行数:101,代码来源:torrenttable_functions.php
示例14: array
}
$stdfoot = array('js' => array('popup'));
$res = sql_query('SELECT o.*, o.added as utadded, u.username
FROM offers AS o LEFT JOIN users AS u ON (u.id=o.userid)
WHERE o.id = ' . $id) or sqlerr(__FILE__, __LINE__);
if (!mysql_num_rows($res)) {
stderr('Error', 'Invalid Offer ID');
}
$num = mysql_fetch_assoc($res);
$added = get_date($num['utadded'], '');
$s = htmlspecialchars($num['offer']);
$HTMLOUT .= '<h3>Details Of Offer: ' . $s . '</h3>';
$HTMLOUT .= "<table border='1' width='750px' cellspacing='0' cellpadding='5'><tr><td align='center' colspan='2'><h1>{$s}</h1></td></tr>";
if ($num['descr']) {
require_once 'include/bbcode_functions.php';
$HTMLOUT .= "<tr><td align='right' valign='top'><b>Description</b></td>\r\n <td align='left' colspan='2' valign='top'>" . format_comment($num['descr']) . "</td></tr>";
}
$HTMLOUT .= "<tr><td align='right'><b>Added</b></td>\r\n<td align='left'>{$added}</td></tr>";
if ($CURUSER['id'] == $num['userid'] || $CURUSER['class'] >= UC_MODERATOR) {
$edit = " | <a class='altlink' href='viewoffers.php?id=" . $id . "&edit_offer'>Edit Offer</a> |";
$delete = " <a class='altlink' href='viewoffers.php?id=" . $id . "&del_offer'>Delete offer</a> ";
if ($num['torrentid'] != 0) {
$reset = "| <a class='altlink' href='viewoffers.php?id=" . $id . "&offer_reset'>Re-set Offer</a>";
}
}
$HTMLOUT .= "<tr>\r\n<td align='right'><b>offered By</b></td><td align='left'>\r\n<a class='altlink' href='userdetails.php?id={$num['userid']}'>{$num['username']}</a> {$edit} {$delete} {$reset} |\r\n<a class='altlink' href='viewoffers.php'><b>All offers</b></a> </td></tr><tr><td align='right'>\r\n<b>Vote for this offer</b></td><td align='left'><a href='viewoffers.php?id=" . $id . "&offer_vote'><b>Vote</b></a>\r\n</td></tr>\r\n" . ($INSTALLER09['reports'] ? "<tr><td align='right'><b>Report Offer</b></td><td align='left'>\r\nfor breaking the rules \r\n<form action='report.php?type=Offer&id={$id}' method='post'><input class='btn' type='submit' name='submit' value='Report Offer' /></form></td>\r\n</tr>" : '');
if ($num['torrentid'] == 0) {
$HTMLOUT .= "<tr><td align='right' valign='top'><b>Accept This Offer</b></td>\r\n <td>\r\n <form method='post' action='viewoffers.php?id=" . $id . "&offer_filled'>\r\n <strong>" . $INSTALLER09['baseurl'] . "/details.php?id=</strong><input type='text' size='10' name='torrentid' value='' /> <input type='submit' value='Fill Offer' class='btn' /><br />\r\n Enter the <b>ID</b> of the torrent. (copy/paste the <strong>ID</strong> from another window/tab the correct ID number)<br /></form></td>\r\n </tr>\n";
} else {
$HTMLOUT .= "<tr><td align='right' valign='top'><b>This Offer was accepted:</b></td><td><a class='altlink' href='details.php?id=" . $num['torrentid'] . "'><b>" . $INSTALLER09['baseurl'] . "/details.php?id=" . $num['torrentid'] . "</b></a></td></tr>";
}
开发者ID:CharlieHD,项目名称:U-232-V2,代码行数:31,代码来源:offer_details.php
示例15: SQL_Query_exec
$reading = true;
if (isset($_GET['inbox']) && $arr["unread"] == "yes") {
SQL_Query_exec("UPDATE messages SET `unread` = 'no' WHERE `id` = {$arr['id']} AND `receiver` = {$CURUSER['id']}");
}
}
if ($arr["unread"] == "yes") {
$format = "font-weight:bold;";
$unread = true;
}
$table[' '] = th_left("<input type=\"checkbox\" name=\"msgs[{$arr['id']}]\" " . ($reading ? "checked='checked'" : "") . " onclick=\"this.form.remove.disabled=true;\" />", 1);
$table['Sender'] = th_left("{$sender}", 1, $format);
$table['Sent_to'] = th_left("{$sentto}", 1, $format);
$table['Subject'] = th_left("<a href=\"javascript:read({$arr['id']});\"><img src=\"" . $site_config["SITEURL"] . "/images/plus.gif\" id=\"img_{$arr['id']}\" class=\"read\" border=\"0\" alt='' /></a> <a href=\"javascript:read({$arr['id']});\">{$subject}</a>", 1, $format);
$table['Date'] = th_left(utc_to_tz($arr['added']), 1, $format);
table($table, $tablefmt);
$display = "<div>" . format_comment($arr['msg']) . "<br /><br />";
if (isset($_GET['inbox']) && is_valid_id($arr["sender"])) {
$display .= "<input type=\"submit\" name=\"compose[{$arr['id']}]\" value=\"Reply\" /> \n";
} elseif (isset($_GET['draft']) || isset($_GET['templates'])) {
$display .= "<input type=\"submit\" name=\"compose[{$arr['id']}]\" value=\"Edit\" /> ";
}
if (isset($_GET['inbox']) && $arr['unread'] == 'yes') {
$display .= "<input type=\"submit\" name=\"mark[{$arr['id']}]\" value=\"Mark as Read\" /> \n";
}
$display .= "<input type=\"submit\" name=\"remove[{$arr['id']}]\" value=\"Delete\" /> \n";
$display .= "</div>";
table(td_left($display, 1, "padding:0 6px 6px 6px"), $tablefmt, "id=\"msg_{$arr['id']}\" style=\"display:none;\"");
}
// if ($count)
//{
$buttons = "<input type=\"button\" value=\"" . T_("SELECTED_DELETE") . "\" onclick=\"this.form.remove.disabled=!this.form.remove.disabled;\" />";
开发者ID:l3oncoder,项目名称:TorrentTrader,代码行数:31,代码来源:mailbox.php
示例16: urlencode
&returnto=<?php
echo urlencode($_SERVER['PHP_SELF']);
?>
'><b>D</b></a>]</font><?php
}
?>
</td></tr>
<tr id="kchangelog<?php
echo $arr['id'];
?>
" style="display:<?php
echo $arr["sticky"] == "yes" ? "" : "none";
?>
;" ><td class="embdded">
<?php
echo format_comment($arr["body"], true);
?>
<br/>
Added by <a href="userdetails.php?id=<?php
echo $arr["userid"];
?>
"><b><?php
echo $arr["username"];
?>
</b></a>
</td></tr>
</table>
<br/>
<?php
}
}
开发者ID:ZenoX2012,项目名称:CyBerFuN-CoDeX,代码行数:31,代码来源:index.php
-
PacktPublishing/Python-Machine-Learning-Second-Edition: Python Machine Learning
阅读:969|2022-08-18
-
sussillo/hfopt-matlab: A parallel, cpu-based matlab implemention of the Hessian
阅读:993|2022-08-17
-
win7系统电脑使用过程中有不少朋友表示遇到过win7系统USB驱动器RAM的状况,当出现win7
阅读:885|2022-11-06
-
emersion/go-ostatus: An OStatus library written in Go
阅读:751|2022-08-17
-
The vCenter Server contains a server-side request forgery (SSRF) vulnerability.
阅读:1064|2022-07-29
-
elipapa/markdown-cv: a simple template to write your CV in a readable markdown f
阅读:509|2022-08-17
-
zju-sclab/NDT-library: These is ndt library for ndt_mapping and ndt_localization
阅读:732|2022-08-16
-
Call Me Maybe 中英字幕 对于加拿大歌手卡莉·蕾·吉普森很多人有些陌生,她隶属于贾
阅读:628|2022-11-06
-
TComponent类TComponent类直接由TPersistent派生。TComponent的独特特征是它的属性能
阅读:892|2022-07-18
-
drac/Material-Design-Color-Palette-for-Inkscape: Google Material Design Color Pa
阅读:364|2022-08-17
|
请发表评论