Lavaliar User Trash N Close Topic Tools
Started on the old forum in June 2007 · view the original in the archive · old links redirect here
The best is to place the code hear so all cant see the code and se if some rong in the code ..Sory for the way i speak .. External image (may be gone)
The best is to place the code hear so all cant see the code and se if some rong in the code ..Sory for the way i speak .. External image (may be gone)
ok here is codes modcp.php
<?php /* IrisBlaze wap forum by Ra'ed Shabana */ header("Content-type: text/vnd.wap.wml"); header("Cache-Control: no-store, no-cache, must-revalidate"); echo("<?xml version=\"1.0\"?>");echo "<!DOCTYPE wml PUBLIC \"-//WAPFORUM//DTD WML 1.1//EN\"". " \"http://www.wapforum.org/DTD/wml_1.1.xml\">"; ?> <wml>
<?php include("config.php"); include("core.php"); connectdb(); $action = $_GET["action"]; $sid = $_GET["sid"]; if(!ismod(getuid_sid($sid))) { echo "<card id=\"main\" title=\"harderstyles.net\">"; echo " "; echo "You are not a mod "; echo " "; echo "<a href=\"index.php\">Home</a>"; echo " "; echo "</card>"; } if(islogged($sid)==false) { echo "<card id=\"main\" title=\"harderstyles.net\">"; echo " "; echo "You are not logged in "; echo "Or Your session has been expired "; echo "<a href=\"index.php\">Login</a>"; echo " "; echo "</card>"; } addonline(getuid_sid($sid),"Mod CP",""); if($action=="main") { echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; echo "**Reports**"; echo " "; echo " "; $nrpm = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_private WHERE reported='1'")); echo "<a href=\"modcp.php?action=rpm&sid=$sid\">»Pr. Messages($nrpm[0])</a> "; $nrps = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_posts WHERE reported='1'")); echo "<a href=\"modcp.php?action=rps&sid=$sid\">»Posts($nrps[0])</a> "; $nrtp = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_topics WHERE reported='1'")); echo "<a href=\"modcp.php?action=rtp&sid=$sid\">»Topics($nrtp[0])</a>"; echo " "; echo " "; echo "**Logs**"; echo " "; echo " "; $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_mlog")); if($noi[0]>0){ $nola = mysql_query("SELECT DISTINCT (action) FROM ibwf_mlog ORDER BY actdt DESC"); while($act=mysql_fetch_array($nola)) { $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_mlog WHERE action='".$act[0]."'")); echo "<a href=\"modcp.php?action=log&sid=$sid&view=$act[0]\">$act[0]($noi[0])</a> "; } } echo " "; echo " "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } /////////////////////////////////Reported PMs else if($action=="rpm") { $page = $_GET["page"]; echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; echo "**Reported PMs**"; echo " "; echo " "; echo ""; if($page=="" || $page<=0)$page=1; $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_private WHERE reported ='1'")); $num_items = $noi[0]; //changable $items_per_page= 5; $num_pages = ceil($num_items/$items_per_page); if($page>$num_pages)$page= $num_pages; $limit_start = ($page-1)*$items_per_page; $sql = "SELECT id, text, byuid, touid, timesent FROM ibwf_private WHERE reported='1' ORDER BY timesent DESC LIMIT $limit_start, $items_per_page"; $items = mysql_query($sql); while ($item=mysql_fetch_array($items)) { $fromnk = getnick_uid($item[2]); $tonick = getnick_uid($item[3]); $dtop = date("d m y - H:i:s", $item[4]); $text = parsepm($item[1]); $flk = "<a href=\"index.php?action=viewuser&sid=$sid&who=$item[2]\">$fromnk</a>"; $tlk = "<a href=\"index.php?action=viewuser&sid=$sid&who=$item[3]\">$tonick</a>"; echo "From: $flk To: $tlk Time: $dtop "; echo $text; echo " "; echo "<a href=\"modproc.php?action=hpm&sid=$sid&pid=$item[0]\">Handle</a> "; } echo ""; echo " "; echo " "; if($page>1) { $ppage = $page-1; echo "<a href=\"modcp.php?action=$action&page=$ppage&sid=$sid\">«PREV</a> "; } if($page<$num_pages) { $npage = $page+1; echo "<a href=\"modcp.php?action=$action&page=$npage&sid=$sid\">Next»</a>"; } echo " $page/$num_pages "; if($num_pages>2) { $rets = "Jump to page<input name=\"pg\" format=\"*N\" size=\"3\"/>"; $rets .= "<anchor>[GO]"; $rets .= "<go href=\"modcp.php\" method=\"get\">"; $rets .= "<postfield name=\"action\" value=\"$action\"/>"; $rets .= "<postfield name=\"sid\" value=\"$sid\"/>"; $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>"; $rets .= "</go></anchor>"; echo $rets; } echo " "; echo "<a href=\"modcp.php?action=main&sid=$sid\">"; echo "Mod R/L</a> "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } /////////////////////////////////Reported Posts else if($action=="rps") { $page = $_GET["page"]; echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; echo "**Reported Posts**"; echo " "; echo " "; echo ""; if($page=="" || $page<=0)$page=1; $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_posts WHERE reported ='1'")); $num_items = $noi[0]; //changable $items_per_page= 5; $num_pages = ceil($num_items/$items_per_page); if($page>$num_pages)$page= $num_pages; $limit_start = ($page-1)*$items_per_page; $sql = "SELECT id, text, tid, uid, dtpost FROM ibwf_posts WHERE reported='1' ORDER BY dtpost DESC LIMIT $limit_start, $items_per_page"; $items = mysql_query($sql); while ($item=mysql_fetch_array($items)) { $poster = getnick_uid($item[3]); $tname = htmlspecialchars(gettname($item[3])); $dtop = date("d m y - H:i:s", $item[4]); $text = parsemsg($item[1]); $flk = "<a href=\"index.php?action=viewuser&sid=$sid&who=$item[3]\">$poster</a>"; $tlk = "<a href=\"index.php?action=viewtpc&sid=$sid&tid=$item[2]\">$tname</a>"; echo "Poster: $flk In: $tlk Time: $dtop "; echo $text; echo " "; echo "<a href=\"modproc.php?action=hps&sid=$sid&pid=$item[0]\">Handle</a> "; } echo ""; echo " "; echo " "; if($page>1) { $ppage = $page-1; echo "<a href=\"modcp.php?action=$action&page=$ppage&sid=$sid\">«PREV</a> "; } if($page<$num_pages) { $npage = $page+1; echo "<a href=\"modcp.php?action=$action&page=$npage&sid=$sid\">Next»</a>"; } echo " $page/$num_pages "; if($num_pages>2) { $rets = "Jump to page<input name=\"pg\" format=\"*N\" size=\"3\"/>"; $rets .= "<anchor>[GO]"; $rets .= "<go href=\"modcp.php\" method=\"get\">"; $rets .= "<postfield name=\"action\" value=\"$action\"/>"; $rets .= "<postfield name=\"sid\" value=\"$sid\"/>"; $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>"; $rets .= "</go></anchor>"; echo $rets; } echo " "; echo "<a href=\"modcp.php?action=main&sid=$sid\">"; echo "Mod R/L</a> "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } /////////////////////////////////Reported Posts else if($action=="log") { $page = $_GET["page"]; $view = $_GET["view"]; echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; echo "**$view**"; echo " "; echo " "; echo ""; if($page=="" || $page<=0)$page=1; $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_mlog WHERE action='".$view."'")); $num_items = $noi[0]; //changable $items_per_page= 5; $num_pages = ceil($num_items/$items_per_page); if($page>$num_pages)$page= $num_pages; $limit_start = ($page-1)*$items_per_page; $sql = "SELECT actdt, details FROM ibwf_mlog WHERE action='".$view."' ORDER BY actdt DESC LIMIT $limit_start, $items_per_page"; $items = mysql_query($sql); while ($item=mysql_fetch_array($items)) { echo "Time: ".date("d m y-H:i:s", $item[0])." "; echo $item[1]; echo " "; } echo ""; echo " "; echo " "; if($page>1) { $ppage = $page-1; echo "<a href=\"modcp.php?action=$action&page=$ppage&sid=$sid&view=$view\">«PREV</a> "; } if($page<$num_pages) { $npage = $page+1; echo "<a href=\"modcp.php?action=$action&page=$npage&sid=$sid&view=$view\">Next»</a>"; } echo " $page/$num_pages "; if($num_pages>2) { $rets = "Jump to page<input name=\"pg\" format=\"*N\" size=\"3\"/>"; $rets .= "<anchor>[GO]"; $rets .= "<go href=\"modcp.php\" method=\"get\">"; $rets .= "<postfield name=\"action\" value=\"$action\"/>"; $rets .= "<postfield name=\"sid\" value=\"$sid\"/>"; $rets .= "<postfield name=\"view\" value=\"$view\"/>"; $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>"; $rets .= "</go></anchor>"; echo $rets; } echo " "; echo "<a href=\"modcp.php?action=main&sid=$sid\">"; echo "Mod R/L</a> "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } /////////////////////////////////Reported Topics else if($action=="rtp") { $page = $_GET["page"]; echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; echo "**Reported Topics**"; echo " "; echo " "; echo ""; if($page=="" || $page<=0)$page=1; $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_topics WHERE reported ='1'")); $num_items = $noi[0]; //changable $items_per_page= 5; $num_pages = ceil($num_items/$items_per_page); if($page>$num_pages)$page= $num_pages; $limit_start = ($page-1)*$items_per_page; $sql = "SELECT id, name, text, authorid, crdate FROM ibwf_topics WHERE reported='1' ORDER BY crdate DESC LIMIT $limit_start, $items_per_page"; $items = mysql_query($sql); while ($item=mysql_fetch_array($items)) { $poster = getnick_uid($item[3]); $tname = htmlspecialchars($item[1]); $dtop = date("d m y - H:i:s", $item[4]); $text = parsemsg($item[2]); $flk = "<a href=\"index.php?action=viewuser&sid=$sid&who=$item[3]\">$poster</a>"; $tlk = "<a href=\"index.php?action=viewtpc&sid=$sid&tid=$item[0]\">$tname</a>"; echo "Poster: $flk In: $tlk Time: $dtop "; echo $text; echo " "; echo "<a href=\"modproc.php?action=htp&sid=$sid&tid=$item[0]\">Handle</a> "; } echo ""; echo " "; echo " "; if($page>1) { $ppage = $page-1; echo "<a href=\"modcp.php?action=$action&page=$ppage&sid=$sid\">«PREV</a> "; } if($page<$num_pages) { $npage = $page+1; echo "<a href=\"modcp.php?action=$action&page=$npage&sid=$sid\">Next»</a>"; } echo " $page/$num_pages "; if($num_pages>2) { $rets = "Jump to page<input name=\"pg\" format=\"*N\" size=\"3\"/>"; $rets .= "<anchor>[GO]"; $rets .= "<go href=\"modcp.php\" method=\"get\">"; $rets .= "<postfield name=\"action\" value=\"$action\"/>"; $rets .= "<postfield name=\"sid\" value=\"$sid\"/>"; $rets .= "<postfield name=\"page\" value=\"$(pg)\"/>"; $rets .= "</go></anchor>"; echo $rets; } echo " "; echo "<a href=\"modcp.php?action=main&sid=$sid\">"; echo "Mod R/L</a> "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } ///////////////////////////////////////////////Mod a user else if($action=="user") { $who = $_GET["who"]; echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $unick = getnick_uid($who); echo "**Moderating $unick**"; echo " "; echo " "; echo "<a href=\"modcp.php?action=penopt&sid=$sid&who=$who\">»Penalties</a> "; echo "<a href=\"modcp.php?action=plsopt&sid=$sid&who=$who\">»Plusses</a> "; if(istrashed($who)) { echo "<a href=\"modproc.php?action=untr&sid=$sid&who=$who\">»Untrash</a> "; } if(isbanned($who)) { echo "<a href=\"modproc.php?action=unbn&sid=$sid&who=$who\">»Unban</a> "; } if(!isshield($who)) { echo "<a href=\"modproc.php?action=shld&sid=$sid&who=$who\">»Shield</a> "; }else{ echo "<a href=\"modproc.php?action=ushld&sid=$sid&who=$who\">»Unshield</a> "; } echo " "; echo " "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } //////////////////////////////////////Penalties Options else if($action=="penopt") { $who = $_GET["who"]; echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $unick = getnick_uid($who); echo "What do you want to do with $unick"; echo " "; echo " "; $pen[0]="Trash"; $pen[1]="Ban"; $pen[2]="Ban Ip"; echo "Penalty: <select name=\"pid\">"; for($i=0;$i<count($pen);$i++) { echo "<option value=\"$i\">$pen[$i]</option>"; } echo "</select> "; echo "Reason: <input name=\"pres\" maxlength=\"100\"/> "; echo "Days: <input name=\"pds\" format=\"*N\" maxlength=\"4\"/> "; echo "Hours: <input name=\"phr\" format=\"*N\" maxlength=\"4\"/> "; echo "Minutes: <input name=\"pmn\" format=\"*N\" maxlength=\"2\"/> "; echo "Seconds: <input name=\"psc\" format=\"*N\" maxlength=\"2\"/> "; echo "<anchor>PUNISH"; echo "<go href=\"modproc.php?action=pun&sid=$sid\" method=\"post\">"; echo "<postfield name=\"who\" value=\"$who\"/>"; echo "<postfield name=\"pid\" value=\"$(pid)\"/>"; echo "<postfield name=\"pres\" value=\"$(pres)\"/>"; echo "<postfield name=\"pds\" value=\"$(pds)\"/>"; echo "<postfield name=\"phr\" value=\"$(phr)\"/>"; echo "<postfield name=\"pmn\" value=\"$(pmn)\"/>"; echo "<postfield name=\"psc\" value=\"$(psc)\"/>"; echo "</go></anchor>"; echo " "; echo " "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } //////////////////////////////////////Penalties Options else if($action=="plsopt") { $who = $_GET["who"]; echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $unick = getnick_uid($who); echo "Add/Substract $unick's Plusses"; echo " "; echo " "; $pen[0]="Substract"; $pen[1]="Add"; echo "Action: <select name=\"pid\">"; for($i=0;$i<count($pen);$i++) { echo "<option value=\"$i\">$pen[$i]</option>"; } echo "</select> "; echo "Reason: <input name=\"pres\" maxlength=\"100\"/> "; echo "Plusses: <input name=\"pval\" format=\"*N\" maxlength=\"3\"/> "; echo "<anchor>Update"; echo "<go href=\"modproc.php?action=pls&sid=$sid\" method=\"post\">"; echo "<postfield name=\"who\" value=\"$who\"/>"; echo "<postfield name=\"pres\" value=\"$(pres)\"/>"; echo "<postfield name=\"pval\" value=\"$(pval)\"/>"; echo "<postfield name=\"pid\" value=\"$(pid)\"/>"; echo "</go></anchor>"; echo " "; echo " "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } else{ echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; echo "I don't know how did you get into here, but there's nothing to show "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } ?> </wml>modproc.php
<?php /* IrisBlaze wap forum by Ra'ed Shabana */ header("Content-type: text/vnd.wap.wml"); header("Cache-Control: no-store, no-cache, must-revalidate"); echo("<?xml version=\"1.0\"?>");echo "<!DOCTYPE wml PUBLIC \"-//WAPFORUM//DTD WML 1.1//EN\"". " \"http://www.wapforum.org/DTD/wml_1.1.xml\">"; ?> <wml>
<?php include("config.php"); include("core.php"); connectdb(); $action = $_GET["action"]; $sid = $_GET["sid"]; if(!ismod(getuid_sid($sid))) { echo "<card id=\"main\" title=\"harderstyles.net\">"; echo " "; echo "You are not a mod "; echo " "; echo "<a href=\"index.php\">Home</a>"; echo " "; echo "</card>"; } if(islogged($sid)==false) { echo "<card id=\"main\" title=\"harderstyles.net\">"; echo " "; echo "You are not logged in "; echo "Or Your session has been expired "; echo "<a href=\"index.php\">Login</a>"; echo " "; echo "</card>"; } addonline(getuid_sid($sid),"Mod CP",""); if($action=="delp") { $pid = $_GET["pid"]; $tid = gettid_pid($pid); $fid = getfid_tid($tid); echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $res = mysql_query("DELETE FROM ibwf_posts WHERE id='".$pid."'"); if($res) { $tname = mysql_fetch_array(mysql_query("SELECT name FROM ibwf_topics WHERE id='".$tid."'")); mysql_query("INSERT INTO ibwf_mlog SET action='posts', details='**".getnick_uid(getuid_sid($sid))."** Deleted Post Number $pid Of the thread ".mysql_escape_string($tname[0])." at the forum ".getfname($fid)."', actdt='".time()."'"); echo "<img src=\"images/ok.gif\" alt=\"O\"/>Post Message Deleted"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } echo " <a href=\"index.php?action=viewtpc&sid=$sid&tid=$tid&page=1000\">"; echo "View Topic</a> "; $fname = getfname($fid); echo "<a href=\"index.php?action=viewfrm&sid=$sid&fid=$fid\">"; echo "$fname</a> "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } ////////////////////////////////////////////Edit Post else if($action=="edtpst") { $pid = $_GET["pid"]; $ptext = $_POST["ptext"]; $tid = gettid_pid($pid); $fid = getfid_tid($tid); echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $res = mysql_query("UPDATE ibwf_posts SET text='" .$ptext."' WHERE id='".$pid."'"); if($res) { $tname = mysql_fetch_array(mysql_query("SELECT name FROM ibwf_topics WHERE id='".$tid."'")); mysql_query("INSERT INTO ibwf_mlog SET action='posts', details='**".getnick_uid(getuid_sid($sid))."** Edited Post Number $pid Of the thread ".mysql_escape_string($tname[0])." at the forum ".getfname($fid)."', actdt='".time()."'"); echo "<img src=\"images/ok.gif\" alt=\"O\"/>Post Message Edited"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } echo " "; echo "<a href=\"index.php?action=viewtpc&sid=$sid&tid=$tid\">"; echo "View Topic</a> "; $fname = getfname($fid); echo "<a href=\"index.php?action=viewfrm&sid=$sid&fid=$fid\">"; echo "$fname</a> "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } ////////////////////////////////////////////Edit Post else if($action=="edttpc") { $tid = $_GET["tid"]; $ttext = $_POST["ttext"]; $fid = getfid_tid($tid); echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $res = mysql_query("UPDATE ibwf_topics SET text='" .$ttext."' WHERE id='".$tid."'"); if($res) { mysql_query("INSERT INTO ibwf_mlog SET action='topics', details='**".getnick_uid(getuid_sid($sid))."** Edited the text Of the thread ".mysql_escape_string(gettname($tid))." at the forum ".getfname($fid)."', actdt='".time()."'"); echo "<img src=\"images/ok.gif\" alt=\"O\"/>Topic Message Edited"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } echo " "; echo "<a href=\"index.php?action=viewtpc&sid=$sid&tid=$tid\">"; echo "View Topic</a> "; $fname = getfname($fid); echo "<a href=\"index.php?action=viewfrm&sid=$sid&fid=$fid\">"; echo "$fname</a> "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } ///////////////////////////////////////Close/ Open Topic else if($action=="clot") { $tid = $_GET["tid"]; $tdo = $_GET["tdo"]; $fid = getfid_tid($tid); echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $res = mysql_query("UPDATE ibwf_topics SET closed='" .$tdo."' WHERE id='".$tid."'"); if($res) { if($tdo==1) { $msg = "Closed"; }else{ $msg = "Opened"; } mysql_query("INSERT INTO ibwf_mlog SET action='topics', details='**".getnick_uid(getuid_sid($sid))."** Closed The thread ".mysql_escape_string(gettname($tid))." at the forum ".getfname($fid)."', actdt='".time()."'"); echo "<img src=\"images/ok.gif\" alt=\"O\"/>Topic $msg"; $tpci = mysql_fetch_array(mysql_query("SELECT name, authorid FROM ibwf_topics WHERE id='".$tid."'")); $tname = htmlspecialchars($tpci[0]); $msg = "your thread [$tname"."](#) is $msg"."[br/][small]*p.s: this is an automatic pm*[/small]"; autopm($msg, $tpci[1]); }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } echo " "; $fname = getfname($fid); echo "<a href=\"index.php?action=viewfrm&sid=$sid&fid=$fid\">"; echo "$fname</a> "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } ///////////////////////////////////////Untrash user else if($action=="untr") { $who = $_GET["who"]; echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $res = mysql_query("DELETE FROM ibwf_penalties WHERE penalty='0' AND uid='".$who."'"); if($res) { $unick = getnick_uid($who); mysql_query("INSERT INTO ibwf_mlog SET action='penalties', details='**".getnick_uid(getuid_sid($sid))."** Untrashed The user **".$unick."', actdt='".time()."'"); echo "<img src=\"images/ok.gif\" alt=\"O\"/>$unick Untrashed"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } echo "** **";** **echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; }** **///////////////////////////////////////Unban user** **else if($action=="unbn") { $who = $_GET["who"]; echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $res = mysql_query("DELETE FROM ibwf_penalties WHERE (penalty='1' OR penalty='2') AND uid='".$who."'"); if($res) { $unick = getnick_uid($who); mysql_query("INSERT INTO ibwf_mlog SET action='penalties', details='".getnick_uid(getuid_sid($sid))."** Unbanned The user **".$unick."**', actdt='".time()."'"); echo "<img src=\"images/ok.gif\" alt=\"O\"/>$unick Unbanned"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } echo " "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } ///////////////////////////////////////Delete shout else if($action=="delsh") { $shid = $_GET["shid"]; echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $sht = mysql_fetch_array(mysql_query("SELECT shouter, shout FROM ibwf_shouts WHERE id='".$shid."'")); $msg = getnick_uid($sht[0]); $msg .= ": ".htmlspecialchars((strlen($sht[1])<20?$sht[1]:substr($sht[1], 0, 20))); $res = mysql_query("DELETE FROM ibwf_shouts WHERE id ='".$shid."'"); if($res) { mysql_query("INSERT INTO ibwf_mlog SET action='shouts', details='**".getnick_uid(getuid_sid($sid))."** Deleted the shout **".$shid."** - $msg', actdt='".time()."'"); echo "<img src=\"images/ok.gif\" alt=\"O\"/>Shout deleted"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } echo " "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } ///////////////////////////////////////Unban user else if($action=="shld") { $who = $_GET["who"]; echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $res = mysql_query("Update ibwf_users SET shield='1' WHERE id='".$who."'"); if($res) { $unick = getnick_uid($who); mysql_query("INSERT INTO ibwf_mlog SET action='penalties', details='**".getnick_uid(getuid_sid($sid))."** Shielded The user **".$unick."**', actdt='".time()."'"); echo "<img src=\"images/ok.gif\" alt=\"O\"/>$unick is Shielded"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } echo " "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } ///////////////////////////////////////Unban user else if($action=="ushld") { $who = $_GET["who"]; echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $res = mysql_query("Update ibwf_users SET shield='0' WHERE id='".$who."'"); if($res) { $unick = getnick_uid($who); mysql_query("INSERT INTO ibwf_mlog SET action='penalties', details='**".getnick_uid(getuid_sid($sid))."** Unshielded The user **".$unick."**', actdt='".time()."'"); echo "<img src=\"images/ok.gif\" alt=\"O\"/>$unick is Unshielded"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } echo " "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } ///////////////////////////////////////Pin/ Unpin Topic else if($action=="pint") { $tid = $_GET["tid"]; $tdo = $_GET["tdo"]; $fid = getfid_tid($tid); echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $pnd = getpinned($fid); if($pnd<=5) { $res = mysql_query("UPDATE ibwf_topics SET pinned='" .$tdo."' WHERE id='".$tid."'"); if($res) { if($tdo==1) { $msg = "Pinned"; }else{ $msg = "Unpinned"; } mysql_query("INSERT INTO ibwf_mlog SET action='topics', details='**".getnick_uid(getuid_sid($sid))."** $msg The thread ".mysql_escape_string(gettname($tid))." at the forum ".getfname($fid)."', actdt='".time()."'"); echo "<img src=\"images/ok.gif\" alt=\"O\"/>Topic $msg"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>You can only pin 5 topics in every forum"; } echo " "; $fname = getfname($fid); echo "<a href=\"index.php?action=viewfrm&sid=$sid&fid=$fid\">"; echo "$fname</a> "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } ///////////////////////////////////Delete the damn thing else if($action=="delt") { $tid = $_GET["tid"]; $fid = getfid_tid($tid); echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $tname=gettname($tid); $res = mysql_query("DELETE FROM ibwf_topics WHERE id='".$tid."'"); if($res) { mysql_query("DELETE FROM ibwf_posts WHERE tid='".$tid."'"); mysql_query("INSERT INTO ibwf_mlog SET action='topics', details='**".getnick_uid(getuid_sid($sid))."** Deleted The thread ".mysql_escape_string($tname)." at the forum ".getfname($fid)."', actdt='".time()."'"); echo "<img src=\"images/ok.gif\" alt=\"O\"/>Topic Deleted"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } echo " "; $fname = getfname($fid); echo "<a href=\"index.php?action=viewfrm&sid=$sid&fid=$fid\">"; echo "$fname</a> "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } ////////////////////////////////////////////Edit Post else if($action=="rentpc") { $tid = $_GET["tid"]; $tname = $_POST["tname"]; $fid = getfid_tid($tid); echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $otname = gettname($tid); if(trim($tname!="")) { $not = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_topics WHERE name LIKE '".$tname."' AND fid='".$fid."'")); if($not[0]==0) { $res = mysql_query("UPDATE ibwf_topics SET name='" .$tname."' WHERE id='".$tid."'"); if($res) { mysql_query("INSERT INTO ibwf_mlog SET action='topics', details='**".getnick_uid(getuid_sid($sid))."** Renamed The thread ".mysql_escape_string($otname)." to ".mysql_escape_string($tname)." at the forum ".getfname($fid)."', actdt='".time()."'"); echo "<img src=\"images/ok.gif\" alt=\"O\"/>Topic Renamed"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Topic Name already exist"; } }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>You must specify a name for the topic"; } echo " "; echo "<a href=\"index.php?action=viewtpc&sid=$sid&tid=$tid\">"; echo "View Topic</a> "; $fname = getfname($fid); echo "<a href=\"index.php?action=viewfrm&sid=$sid&fid=$fid\">"; echo "$fname</a> "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } ///////////////////////////////////////////////////Move topic else if($action=="mvt") { $tid = $_GET["tid"]; $mtf = $_POST["mtf"]; $fname = htmlspecialchars(getfname($mtf)); //$fid = getfid_tid($tid); echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $not = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_topics WHERE name LIKE '".$tname."' AND fid='".$mtf."'")); if($not[0]==0) { $res = mysql_query("UPDATE ibwf_topics SET fid='" .$mtf."', moved='1' WHERE id='".$tid."'"); if($res) { mysql_query("INSERT INTO ibwf_mlog SET action='topics', details='**".getnick_uid(getuid_sid($sid))."** Moved The thread ".mysql_escape_string($tname)." to forum ".getfname($fid)."', actdt='".time()."'"); $tpci = mysql_fetch_array(mysql_query("SELECT name, authorid FROM ibwf_topics WHERE id='".$tid."'")); $tname = htmlspecialchars($tpci[0]); $msg = "your thread [$tname"."](#) Was moved to $fname forum[br/][small]*p.s: this is an automatic pm*[/small]"; autopm($msg, $tpci[1]); echo "<img src=\"images/ok.gif\" alt=\"O\"/>Topic Moved"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Topic Name already exist"; } echo " "; echo "<a href=\"index.php?action=viewfrm&sid=$sid&fid=$mtf\">"; echo "$fname</a> "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } //////////////////////////////////////////Handle PM else if($action=="hpm") { $pid = $_GET["pid"]; echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $info = mysql_fetch_array(mysql_query("SELECT byuid, touid FROM ibwf_private WHERE id='".$pid."'")); $res = mysql_query("UPDATE ibwf_private SET reported='2' WHERE id='".$pid."'"); if($res) { mysql_query("INSERT INTO ibwf_mlog SET action='handling', details='**".getnick_uid(getuid_sid($sid))."** handled The PM ".$pid."', actdt='".time()."'"); echo "<img src=\"images/ok.gif\" alt=\"O\"/>PM Handled"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } echo " "; echo "<a href=\"index.php?action=viewuser&sid=$sid&who=$info[0]\">PM Sender's Profile</a> "; echo "<a href=\"index.php?action=viewuser&sid=$sid&who=$info[1]\">PM Reporter's Profile</a> "; echo "<a href=\"modcp.php?action=main&sid=$sid\">"; echo "Mod R/L</a> "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } //////////////////////////////////////////Handle Post else if($action=="hps") { $pid = $_GET["pid"]; echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $info = mysql_fetch_array(mysql_query("SELECT uid, tid FROM ibwf_posts WHERE id='".$pid."'")); $res = mysql_query("UPDATE ibwf_posts SET reported='2' WHERE id='".$pid."'"); if($res) { mysql_query("INSERT INTO ibwf_mlog SET action='handling', details='**".getnick_uid(getuid_sid($sid))."** handled The Post ".$pid."', actdt='".time()."'"); echo "<img src=\"images/ok.gif\" alt=\"O\"/>Post Handled"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } echo " "; $poster = getnick_uid($info[0]); echo "<a href=\"index.php?action=viewuser&sid=$sid&who=$info[0]\">$poster's Profile</a> "; echo "<a href=\"index.php?action=viewtpc&sid=$sid&tid=$info[1]\">View Topic</a> "; echo "<a href=\"modcp.php?action=main&sid=$sid\">"; echo "Mod R/L</a> "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } //////////////////////////////////////////Handle Topic else if($action=="htp") { $pid = $_GET["tid"]; echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $info = mysql_fetch_array(mysql_query("SELECT authorid FROM ibwf_topics WHERE id='".$pid."'")); $res = mysql_query("UPDATE ibwf_topics SET reported='2' WHERE id='".$pid."'"); if($res) { mysql_query("INSERT INTO ibwf_mlog SET action='handling', details='**".getnick_uid(getuid_sid($sid))."** handled The topic ".mysql_escape_string(gettname($pid))."', actdt='".time()."'"); echo "<img src=\"images/ok.gif\" alt=\"O\"/>Topic Handled"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } echo " "; $poster = getnick_uid($info[0]); echo "<a href=\"index.php?action=viewuser&sid=$sid&who=$info[0]\">$poster's Profile</a> "; echo "<a href=\"index.php?action=viewtpc&sid=$sid&tid=$pid\">View Topic</a> "; echo "<a href=\"modcp.php?action=main&sid=$sid\">"; echo "Mod R/L</a> "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } ////////////////////////////////////////Punish else if($action=="pun") { $pid = $_POST["pid"]; $who = $_POST["who"]; $pres = $_POST["pres"]; $pds = $_POST["pds"]; $phr = $_POST["phr"]; $pmn = $_POST["pmn"]; $psc = $_POST["psc"]; echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $uip = ""; $ubr = ""; $pmsg[0]="Trashed"; $pmsg[1]="Banned"; $pmsg[2]="IP-Banned"; if($pid=='2') { //ip ban $uip = getip_uid($who); $ubr = getbr_uid($who); } if(trim($pres)=="") { echo "<img src=\"images/notok.gif\" alt=\"X\"/>You must Specify a reson for punishing the user"; }else{ $timeto = $pds*24*60*60; $timeto += $phr*60*60; $timeto += $pmn*60; $timeto += $psc; $ptime = $timeto + time(); $unick = getnick_uid($who); $res = mysql_query("INSERT INTO ibwf_penalties SET uid='".$who."', penalty='".$pid."', exid='".getuid_sid($sid)."', timeto='".$ptime."', pnreas='".mysql_escape_string($pres)."', ipadd='".$uip."', browserm='".$ubr."'"); if($res) { mysql_query("UPDATE ibwf_users SET lastpnreas='".$pmsg[$pid].": ".mysql_escape_string($pres)."' WHERE id='".$who."'"); mysql_query("INSERT INTO ibwf_mlog SET action='penalties', details='**".getnick_uid(getuid_sid($sid))."** $pmsg[$pid] The user **".$unick."** For ".$timeto." Seconds', actdt='".time()."'"); echo "<img src=\"images/ok.gif\" alt=\"O\"/>$unick is $pmsg[$pid] for $timeto Seconds"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } } echo " <a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } ////////////////////////////////////////Punish else if($action=="pls") { $pid = $_POST["pid"]; $who = $_POST["who"]; $pres = $_POST["pres"]; $pval = $_POST["pval"]; echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; $unick = getnick_uid($who); $opl = mysql_fetch_array(mysql_query("SELECT plusses FROM ibwf_users WHERE id='".$who."'")); if($pid=='0') { $npl = $opl[0] - $pval; }else{ $npl = $opl[0] + $pval; } if($npl<0) { $npl=0; } if(trim($pres)=="") { echo "<img src=\"images/notok.gif\" alt=\"X\"/>You must Specify a reson for updating $unick's Plusses"; }else{ $res = mysql_query("UPDATE ibwf_users SET lastplreas='".mysql_escape_string($pres)."', plusses='".$npl."' WHERE id='".$who."'"); if($res) { mysql_query("INSERT INTO ibwf_mlog SET action='penalties', details='**".getnick_uid(getuid_sid($sid))."** Updated **".$unick."** plusses from ".$opl[0]." to $npl', actdt='".time()."'"); echo "<img src=\"images/ok.gif\" alt=\"O\"/>$unick's Plusses Updated From $opl[0] to $npl"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Database Error"; } } echo " <a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } else{ echo "<card id=\"main\" title=\"Mod CP\">"; echo " "; echo "I don't know how did you get into here, but there's nothing to show "; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo " </card>"; } ?> </wml>Replace your file with this. http://www.2wap.org/forums/index.php?act=a...post&id=925
Replace your file with this. http://www.2wap.org/forums/index.php?act=a...post&id=925
i replaced modcp & modproc ,but no change,still trash & topic close tool r nt working External image (may be gone)