本文整理汇总了PHP中safeChar函数的典型用法代码示例。如果您正苦于以下问题:PHP safeChar函数的具体用法?PHP safeChar怎么用?PHP safeChar使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了safeChar函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的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();
}
示例2: 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();
}
示例3: newmsg
function newmsg($heading = '', $text = '', $div = 'success', $htmlstrip = false)
{
if ($htmlstrip) {
$heading = safeChar(trim($heading));
$text = safeChar(trim($text));
}
print "<table class=\"main\" width=\"100%\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\"><tr><td class=\"embedded\">\n";
print "<div class=\"{$div}\">" . ($heading ? "<b>{$heading}</b><br />" : "") . "{$text}</div></td></tr></table>\n";
}
示例4: makeSafeText
function makeSafeText($arr)
{
foreach ($arr as $k => $v) {
if (is_array($v)) {
$arr[$k] = makeSafeText($v);
} else {
$arr[$k] = safeChar($v);
}
}
return $arr;
}
示例5: stdmsg2
function stdmsg2($heading, $text, $htmlstrip = false)
{
if ($htmlstrip) {
$heading = safeChar($heading);
$text = safeChar($text);
}
print "<table class=main width=750 border=0 cellpadding=0 cellspacing=0><tr><td class=embedded>\n";
if ($heading) {
print "<h2>{$heading}</h2>\n";
}
print "<table width=100% border=1 cellspacing=0 cellpadding=10><tr><td class=text>\n";
print $text . "</td></tr></table></td></tr></table>\n";
}
示例6: array
}
$apps = array('Burning', 'Encoding', 'Anti-Virus', 'Office', 'Os', 'Misc', 'Image');
for ($x = 0; $x < count($apps); $x++) {
echo "<label><input type=\"checkbox\" value=\"{$apps[$x]}\" name=\"apps[]\" class=\"DEPENDS ON genre BEING apps\">{$apps[$x]}</label>";
}
?>
</td></tr></table>
</td></tr>
<?php
echo "<tr><td colspan=\"2\" align=\"center\"><input type=\"submit\" value='Edit it!' style='height: 25px; width: 100px'> <input type=reset value='Revert changes' style='height: 25px; width: 100px'></td></tr>\n";
echo "</table>\n";
echo "</form>\n";
echo "<p>\n";
echo "<form method=\"post\" action=\"delete.php\">\n";
echo "<table border=\"1\" cellspacing=\"0\" cellpadding=\"5\">\n";
echo "<tr><td class=embedded style='background-color: #000000;padding-bottom: 5px' colspan=\"2\"><b>Delete torrent.</b> Reason:</td></tr>";
echo "<td><input name=\"reasontype\" type=\"radio\" value=\"1\"> Dead </td><td> 0 seeders, 0 leechers = 0 peers total</td></tr>\n";
echo "<tr><td><input name=\"reasontype\" type=\"radio\" value=\"2\"> Dupe</td><td><input type=\"text\" size=\"40\" name=\"reason[]\"></td></tr>\n";
echo "<tr><td><input name=\"reasontype\" type=\"radio\" value=\"3\"> Nuked</td><td><input type=\"text\" size=\"40\" name=\"reason[]\"></td></tr>\n";
echo "<tr><td><input name=\"reasontype\" type=\"radio\" value=\"4\"> {$BASEURL} rules</td><td><input type=\"text\" size=\"40\" name=\"reason[]\">(req)</td></tr>";
echo "<tr><td><input name=\"reasontype\" type=\"radio\" value=\"5\" checked> Other:</td><td><input type=\"text\" size=\"40\" name=\"reason[]\">(req)</td></tr>\n";
echo "<input type=\"hidden\" name=\"id\" value=\"{$id}\">\n";
if (isset($_GET["returnto"])) {
echo "<input type=\"hidden\" name=\"returnto\" value=\"" . safeChar($_GET["returnto"]) . "\" />\n";
}
echo "<td colspan=\"2\" align=\"center\"><input type=submit value='Delete it!' style='height: 25px'></td></tr>\n";
echo "</table>";
echo "</form>\n";
echo "</p>\n";
}
stdfoot();
示例7: prefixed
$downspeed = $arr["downspeed"] > 0 ? prefixed($arr["downspeed"]) : ($arr["leechtime"] > 0 ? prefixed($arr["downloaded"] / $arr["leechtime"]) : prefixed(0));
$ratio = $arr["downloaded"] > 0 ? number_format($arr["uploaded"] / $arr["downloaded"], 3) : ($arr["uploaded"] > 0 ? "Inf." : "---");
$completed = sprintf("%.2f%%", 100 * (1 - $arr["to_go"] / $arr["size"]));
$res9 = mysql_query("SELECT seeder FROM peers WHERE torrent={$_GET['id']} AND userid={$arr['userid']}");
$arr9 = mysql_fetch_assoc($res9);
echo "<tr>\n";
echo "<td align=left><a href=userdetails.php?id={$arr['userid']}>{$arr['username']}</a>" . get_user_icons($arr) . "</td>\n";
echo "<td align=right>" . safeChar($arr["id"]) . "</td>\n";
echo "<td align=center>" . ($arr["connectable"] == "yes" ? "<img src=/pic/online.gif>" : "<img src=/pic/offline.gif>") . "</td>\n";
echo "<td align=right>" . prefixed($arr["uploaded"]) . "</td>\n";
echo "<td align=right>{$upspeed}/s</td>\n";
echo "<td align=right>" . prefixed($arr["downloaded"]) . "</td>\n";
echo "<td align=right>{$downspeed}/s</td>\n";
echo "<td align=right>{$ratio}</td>\n";
echo "<td align=right>{$completed}</td>\n";
echo "<td align=right>" . safeChar($arr["hit_and_run"]) . "</td>\n";
echo "<td align=right>" . safeChar($arr["mark_of_cain"]) . "</td>\n";
echo "<td align=right><center><b>" . get_snatched_color($arr["seedtime"]) . "</b></center></td>\n";
echo "<td align=right>" . mkprettytime($arr["leechtime"]) . "</td>\n";
echo "<td align=center>{$arr['last_action']}</td>\n";
echo "<td align=center>" . safeChar($arr["complete_date"] == "0000-00-00 00:00:00" ? "Not Complete Yet" : $arr["complete_date"]) . "</td>\n";
echo "<td align=center>" . safeChar($arr[port]) . "</td>\n";
echo "<td align=center>" . ($arr9["seeder"] == "yes" ? "<img src=" . $pic_base_url . "online.gif border=0 alt=\"active Seeder\">" : "<img src=" . $pic_base_url . "offline.gif border=0 alt=\"Not seeding!\">") . "</td>\n";
echo "<td align=right>" . safeChar($arr["timesann"]) . "</td>\n";
echo "</tr>\n";
}
echo "</table>\n";
if ($count > $perpage) {
echo "{$pagerbottom}";
}
stdfoot();
示例8: dooptimizedb
function dooptimizedb()
{
global $SITENAME, $CURUSER, $DEFAULTBASEURL, $optimizedb_interval, $queries, $query_stat;
set_time_limit(1200);
$result = mysql_query("show processlist") or sqlerr(__FILE__, __LINE__);
while ($row = mysql_fetch_array($result)) {
if ($row["Time"] > 100 || $row["Command"] == "Sleep") {
$sql = "kill " . $row["Id"] . "";
mysql_query($sql) or sqlerr(__FILE__, __LINE__);
}
}
ignore_user_abort(1);
$alltables = mysql_query("SHOW TABLES") or sqlerr(__FILE__, __LINE__);
while ($table = mysql_fetch_assoc($alltables)) {
foreach ($table as $db => $tablename) {
$sql = "OPTIMIZE TABLE {$tablename}";
/* Preg match the sql incase it was hijacked somewhere!(will use CHECK|ANALYZE|REPAIR|later) */
if (preg_match('@^(CHECK|ANALYZE|REPAIR|OPTIMIZE)[[:space:]]TABLE[[:space:]]' . $tablename . '$@i', $sql)) {
@mysql_query($sql) or die("<b>Something was not right!</b>.\n<br />Query: " . $sql . "<br />\nError: (" . mysql_errno() . ") " . safeChar(mysql_error()));
}
}
}
@mysql_free_result($alltables);
write_log("autooptimizedb", " --------------------Auto Optimization Complete using {$queries} queries --------------------");
}
示例9: insert_compose_frame
function insert_compose_frame($id, $newtopic = true, $quote = false, $attachment = false)
{
global $maxsubjectlength, $CURUSER, $max_torrent_size, $maxfilesize, $pic_base_url, $use_attachment_mod, $forum_pics, $DEFAULTBASEURL;
if ($newtopic) {
$res = sql_query("SELECT name FROM forums WHERE id = " . sqlesc($id)) or sqlerr(__FILE__, __LINE__);
$arr = mysql_fetch_assoc($res) or die("Bad forum ID!");
?>
<h3>New topic in <a href='<?php
echo $_SERVER['PHP_SELF'];
?>
?action=viewforum&forumid=<?php
echo $id;
?>
'><?php
echo safeChar($arr["name"]);
?>
</a> forum</h3><?php
} else {
$res = sql_query("SELECT subject, locked FROM topics WHERE id = " . sqlesc($id)) or sqlerr(__FILE__, __LINE__);
$arr = mysql_fetch_assoc($res) or die("Forum error, Topic not found.");
if ($arr['locked'] == 'yes') {
stdmsg("Sorry", "The topic is locked.");
end_table();
end_main_frame();
stdfoot();
exit;
}
?>
<h3 align="center"><?php
echo $language['replyto'];
?>
<a href='<?php
echo $_SERVER['PHP_SELF'];
?>
action=viewtopic&topicid=<?php
echo $id;
?>
'><?php
echo safeChar($arr["subject"]);
?>
</a></h3><?php
}
begin_frame("Compose", true);
?>
<form method='post' name='compose' action='<?php
echo $_SERVER['PHP_SELF'];
?>
' enctype='multipart/form-data'>
<input type="hidden" name="action" value="post" />
<input type='hidden' name='<?php
echo $newtopic ? 'forumid' : 'topicid';
?>
' value='<?php
echo $id;
?>
' /><?php
begin_table(true);
if ($newtopic) {
?>
<tr>
<td class='rowhead' width="10%">Subject</td>
<td align='left'>
<input type='text' size='100' maxlength='<?php
echo $maxsubjectlength;
?>
' name='subject' style='height: 19px' />
</td>
</tr><?php
}
if ($quote) {
$postid = (int) $_GET["postid"];
if (!is_valid_id($postid)) {
stdmsg("Error", "Invalid ID!");
end_table();
end_main_frame();
stdfoot();
exit;
}
$res = sql_query("SELECT posts.*, users.username FROM posts JOIN users ON posts.userid = users.id WHERE posts.id = {$postid}") or sqlerr(__FILE__, __LINE__);
if (mysql_num_rows($res) == 0) {
stdmsg("Error", "No post with this ID");
end_table();
end_main_frame();
stdfoot();
exit;
}
$arr = mysql_fetch_assoc($res);
}
?>
<tr>
<td class='rowhead' width="10%">Body</td>
<td><?php
$qbody = $quote ? "[quote=" . safeChar($arr["username"]) . "]" . safeChar(unesc($arr["body"])) . "[/quote]" : '';
if (function_exists('textbbcode')) {
textbbcode("compose", "body", $qbody);
} else {
?>
<textarea name="body" style="width:99%" rows="7"><?php
echo $qbody;
?>
//.........这里部分代码省略.........
示例10: header
<?php
// CyBerFuN.Ro
// By CyBerNe7
// //
// http://cyberfun.ro/
// http://xlist.ro/
header("Content-Type: text/html; charset=iso-8859-1");
require_once "include/bittorrent.php";
dbconn();
if (!logged_in()) {
header("HTTP/1.0 404 Not Found");
// moddifed logginorreturn by retro//Remember to change the following line to match your server
print "<html><h1>Not Found</h1><p>The requested URL /{$_SERVER['PHP_SELF']} was not found on this server.</p><hr /><address>Apache/1.1.11 " . $SITENAME . " Server at " . $_SERVER['SERVER_NAME'] . " Port 80</address></body></html>\n";
die;
}
$id = 0 + $_GET["id"];
$s = "<table width=500 class=colorss class=main border=\"1\" cellspacing=0 cellpadding=\"5\">\n";
$subres = sql_query("SELECT * FROM files WHERE torrent = {$id} ORDER BY id");
$s .= "<tr><td width=500 class=colhead>Type</td><td class=colhead>Path</td><td class=colhead align=right>Size</td></tr>\n";
while ($subrow = mysql_fetch_array($subres)) {
preg_match('/\\.([A-Za-z0-9]+)$/', $subrow["filename"], $ext);
$ext = strtolower($ext[1]);
if (!file_exists("pic/icons/" . $ext . ".png")) {
$ext = "Unknown";
}
$s .= "<tr><td align\"center\"><img align=center src=\"pic/icons/" . $ext . ".png\" alt=\"{$ext} file\"></td><td class=tableb2 width=700>" . safeChar($subrow["filename"]) . "</td><td align=\"right\">" . prefixed($subrow["size"]) . "</td></tr>\n";
}
$s .= "</table>\n";
echo $s;
示例11: hacker_dork
hacker_dork("Secure Ip - Nosey Cunt !");
}
// in the case part add staff names exactly as they are on site
//example
//case 'Admin':
//case 'System':
// and so on
switch ($_POST['staffname']) {
case 'Mindless':
case 'System':
$name = safeChar($_POST['staffname']);
$pass = safeChar($_POST['secrettop']);
break;
default:
$naughtyboy = getip();
$name = safeChar($_POST['staffname']);
$msg = "Someone is trying to login through the Staff login page with the name {$name} and ip {$naughtyboy}";
$subject = "ALERT Failed staff login attempt";
// change id to your id to recieve a pm if someone tried to login with failed name or just comment it out
mysql_query("INSERT INTO messages (sender, receiver, added, msg, poster) VALUES (0, 1, '" . get_date_time() . "', " . sqlesc($msg) . ", 0)") or sqlerr(__FILE__, __LINE__);
stderr("Error", "WARNING ! You're not a staff member");
die;
break;
}
//Just keep adding the elseif and validpass until all staff have been added..
if ($_POST['staffname'] == "Mindless") {
$validpass = "embassy1";
} elseif ($_POST['staffname'] == "System") {
$validpass = "richmond1";
} else {
die;
示例12: htmlentities
$usernamegift = htmlentities(trim($_POST['username']));
$res = sql_query("SELECT id,uploaded,bonuscomment,username FROM users WHERE username=" . sqlesc($usernamegift));
$arr = mysql_fetch_assoc($res);
$useridgift = $arr['id'];
$userupload = $arr['uploaded'];
$bonuscomment_gift = $arr['bonuscomment'];
$usernamegift = $arr['username'];
$mb_basic = 1024 * 1024;
if (isset($_POST['unit'])) {
if ($_POST["unit"] == '2') {
$nobits = $_POST["amnt"] * $mb_basic * 1024;
}
}
$amt1 = $_POST["amnt"];
if ($ubonus >= $nobits) {
$upgift = safeChar($upgift, 1);
$bonuscomment = gmdate("Y-m-d") . " - " . prefixed($nobits) . " Upload Credit as gift to {$usernamegift} .\n " . $bonuscomment;
$bonuscomment_gift = gmdate("Y-m-d") . " - recieved " . prefixed($nobits) . " Upload Credit as gift from {$CURUSER['username']} .\n " . $bonuscomment_gift;
$upbonus = $ubonus - $nobits;
$upbonus1 = $userupload + $nobits;
if ($userid == $useridgift) {
header("Refresh: 0; url={$BASEURL}/mybonus.php?gift_fail1=1");
die;
}
if (!$useridgift) {
header("Refresh: 0; url={$BASEURL}/mybonus.php?gift_fail_user=1");
die;
}
if ($amt1 <= 0) {
header("Refresh: 0; url={$BASEURL}/mybonus.php?gift_fail2=1");
die;
示例13: hacker_dork
die;
}
if (get_user_class() < UC_MODERATOR) {
hacker_dork("Admin Bookmarks - Nosey Cunt !");
}
stdhead("Staff Bookmarks");
begin_main_frame();
$addbookmark = number_format(get_row_count("users", "WHERE addbookmark='yes'"));
begin_frame("In total ({$addbookmark})", true);
begin_table();
?>
<table cellpadding="4" cellspacing="1" border="0" style="width:800px" class="tableinborder" ><tr><td class="tabletitle">ID</td><td class="tabletitle" align="left">Username</td><td class="tabletitle" align="left">Suspicion</td><td class="tabletitle" align="left">Uploaded</td><td class="tabletitle" align="left">Downloaded</td><td class="tabletitle" align="left">Ratio</td></tr>
<?php
$res = mysql_query("SELECT id,username,bookmcomment,uploaded,downloaded FROM users WHERE addbookmark='yes' ORDER BY id") or print mysql_error();
while ($arr = @mysql_fetch_assoc($res)) {
if ($arr["downloaded"] != 0) {
$ratio = number_format($arr["uploaded"] / $arr["downloaded"], 3);
} else {
$ratio = "---";
}
$ratio = "<font color=" . get_ratio_color($ratio) . ">{$ratio}</font>";
$uploaded = prefixed($arr["uploaded"]);
$downloaded = prefixed($arr["downloaded"]);
$uploaded = str_replace(" ", "<br>", prefixed($arr["uploaded"]));
$downloaded = str_replace(" ", "<br>", prefixed($arr["downloaded"]));
echo "<tr><td class=table >" . safeChar($arr[id]) . "</td><td class=table align=\"left\"><b><a href=userdetails.php?id=" . safeChar($arr[id]) . ">" . safeChar($arr[username]) . "</b></td><td class=table align=\"left\">" . safeChar($arr[bookmcomment]) . "</a></td><td class=table align=\"left\">" . $uploaded . "</td></a></td><td class=table align=\"left\">" . $downloaded . "</td><td class=table align=\"left\">{$ratio}</td></tr>";
}
end_main_frame();
end_frame();
end_table();
stdfoot();
示例14: begin_table
}
begin_table();
echo "<p align=center><a class=altlink href=donations.php>Current Donors</a> || <a class=altlink href=donations.php?total_donors=1>All Donations</a></p>";
echo $pagertop;
echo "<tr><td class=colhead>ID</td><td class=colhead align=left>Username</td><td class=colhead align=left>e-mail</td>" . "<td class=colhead align=left>Joined</td><td class=colhead align=left>Donor Until?</td><td class=colhead align=left>" . "Current</td><td class=colhead align=left>Total</td><td class=colhead align=left>PM</td></tr>";
while ($arr = @mysql_fetch_assoc($res)) {
// =======change colors
if ($count2 == 0) {
$count2 = $count2 + 1;
$class = "clearalt7";
} else {
$count2 = 0;
$class = "clearalt6";
}
// =======end
echo "<tr><td valign=bottom class={$class}><a class=altlink href=userdetails.php?id=" . safeChar($arr[id]) . ">" . safeChar($arr[id]) . "</a></td>" . "<td align=left valign=bottom class={$class}><b><a class=altlink href=userdetails.php?id=" . safeChar($arr[id]) . ">" . safeChar($arr[username]) . "</b>" . "</td><td align=left valign=bottom class={$class}><a class=altlink href=mailto:" . safeChar($arr[email]) . ">" . safeChar($arr[email]) . "</a>" . "</td><td align=left valign=bottom class={$class}><font size=\"-3\">" . safeChar($arr[added]) . "</font></a>" . "</td><td align=left valign=bottom class={$class}>";
$r = @mysql_query("SELECT donoruntil FROM users WHERE id=" . sqlesc($arr[id]) . "") or sqlerr();
$user = mysql_fetch_array($r);
$donoruntil = $user['donoruntil'];
if ($donoruntil == '0000-00-00 00:00:00') {
echo "n/a";
} else {
echo "<font size=\"-3\"><p>{$donoruntil} [ " . mkprettytime(strtotime($donoruntil) - gmtime()) . " ] to go...</font></p>";
}
echo "</td><td align=left valign=bottom class={$class}><b>£" . safeChar($arr[donated]) . "</b></td>" . "<td align=left valign=bottom class={$class}><b>£" . safeChar($arr[total_donated]) . "</b></td>" . "<td align=left valign=bottom class={$class}><b><a class=altlink href=sendmessage.php?receiver=" . safeChar($arr[id]) . ">PM</a></b></td></tr>";
}
end_table();
end_frame();
echo $pagerbottom;
stdfoot();
die;
示例15: dbconn
require_once "include/bbcode_functions.php";
dbconn(false);
maxcoder();
if (!logged_in()) {
header("HTTP/1.0 404 Not Found");
// moddifed logginorreturn by retro//Remember to change the following line to match your server
print "<html><h1>Not Found</h1><p>The requested URL /{$_SERVER['PHP_SELF']} was not found on this server.</p><hr /><address>Apache/1.1.11 " . $SITENAME . " Server at " . $_SERVER['SERVER_NAME'] . " Port 80</address></body></html>\n";
die;
}
if (get_user_class() < UC_SYSOP) {
hacker_dork("Shout History - Nosey Cunt !");
}
stdhead("Admin Shout History Check");
$count1 = number_format(get_row_count("shoutbox"));
print "<h2 align=center>Full Shout History</h2>";
print "<center><font class=small>We currently have " . safeChar($count1) . " shouts on history</font></center>";
begin_main_frame();
$res1 = mysql_query("SELECT COUNT(*) FROM shoutbox {$limit}") or sqlerr();
$row1 = mysql_fetch_array($res1);
$count = $row1[0];
$shoutsperpage = 30;
list($pagertop, $pagerbottom, $limit) = pager($shoutsperpage, $count, "shistory.php?");
print "{$pagertop}";
$res = sql_query("SELECT * FROM shoutbox ORDER BY date DESC {$limit}") or sqlerr(__FILE__, __LINE__);
if (mysql_num_rows($res) == 0) {
print "\n";
} else {
print "<table border=0 cellspacing=0 cellpadding=2 width='100%' align='left' class='small'>\n";
$i = 0;
while ($arr = mysql_fetch_assoc($res)) {
$res2 = sql_query("SELECT username,class,donor,warned,downloadpos,chatpost,forumpost,uploadpos,parked FROM users WHERE id=" . unsafeChar($arr[userid]) . "") or sqlerr(__FILE__, __LINE__);