Basic TBDEV 08 Staffpanel

Started by rushed, December 09, 2012, 04:36:00 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

DarkMaster

Quote from: Payaa on December 09, 2012, 06:36:16 PM
Then U can use the maxsysop function with little edit. I use it in my own so that not just staffpanel then every page where are just the staff stay :)

its a decent function to use, i used it with my old dev source.. was effective for me then
Please Place All Support Questions In The Right Section

Payaa

Then U can use the maxsysop function with little edit. I use it in my own so that not just staffpanel then every page where are just the staff stay :)

rushed

your right Payaa I ony added that as I as a site coder prefer to know who is trying to get where they shouldnt be

Payaa

Its cool!

But I think this enough for that on staffpanel(no need message):
if (get_user_class() < UC_MODERATOR){
        stderr("Error", "Access denied.");
die();
}

rushed

#1
Something I did very quickly for another site code can prolly be hugely improved upon it does have  a feature where if a user below mod (or your lowest staff class) tries to access it a pm is sent to a designated user changed VALUES (0, 10 <------ the 10 to whatever userid you like

http://i.imgur.com/MqGlu.png
http://i.imgur.com/KsMIg.png
http://i.imgur.com/ojwXK.png

and heres what happens if a non staff member tries to access it



<?php
/*********************************************************************
Full credits to the original source creators retro plus many many more
Coded by oneclub for Bitsoup.org
**********************************************************************/
require_once("include/bittorrent.php");
dbconn();
loggedinorreturn();
stdhead("Staff Tools");
$msg"someone illegally tried to access the staff panel!";
        
$subject =  sqlesc("Someone tried to access staff panel");
    
$user $CURUSER['username'];
        
$body  sqlesc("User $user has tried to access the staff panel, they are not permitted to be here");
       
$dt sqlesc(get_date_time());

if (
get_user_class() < UC_MODERATOR){

    
mysql_query("INSERT INTO messages (sender, receiver, added,  msg) VALUES (0, 1, $dt$body)") or sqlerr(__FILE____LINE__);

stdmsg("Error""Access is denied to none staff");
stdfoot();
exit();
}



?>



<?phpif (get_user_class() >= UC_MODERATOR){?>

<h2>Moderator Tools</h2>

<table width="100%" border="1" cellspacing="0" cellpadding="10"><tbody><tr><td>

<br>
<table width="500" cellspacing="3">
<tbody><tr>
<td class="embedded"></td>

</tr>

</tbody></table>
<table width="500" cellspacing="10" align="center">
<tbody><tr>
<td class="embedded"><form method="get" action="reports.php"><input type="submit" value="Reports" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="recover.php"><input type="submit" value="Recover Account" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="uncon.php"><input type="submit" value="None Connectable" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="polls.php"><input type="submit" value="Poll Overview" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="users.php"><input type="submit" value="User List" style="height: 25px; width: 100px"></form></td>
</tr><tr>

<td class="embedded"><form method="get" action="log.php"><input type="submit" value="Site Log" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="topeleven.php"><input type="submit" value="Top 10" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="adminbookmark.php"><input type="submit" value="Suspect List" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="stats.php"><input type="submit" value="Tracker Stats" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="comments.php"><input type="submit" value="Torrent Comments" style="height: 25px; width: 100px"></form></td>
</tr>
</tbody></table>
<br>

</td></tr></tbody></table>

<?php }?>
<?phpif (get_user_class() >= UC_ADMINISTRATOR){?>

<h2>Administrator Tools</h2>

<table width="100%" border="1" cellspacing="0" cellpadding="10"><tbody><tr><td>

<br>
<table width="500" cellspacing="3">
<tbody><tr>
<td class="embedded"></td>

</tr>

</tbody></table>
<table width="500" cellspacing="10" align="center">
<tbody><tr>
<td class="embedded"><form method="get" action="delacctadmin.php"><input type="submit" value="Delete Users" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="bans.php"><input type="submit" value="IP Ban List" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="leechblock.php"><input type="submit" value="Leech Block" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="usersearch.php"><input type="submit" value="Admin Search" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="pitboss.php"><input type="submit" value="Casino Log" style="height: 25px; width: 100px"></form></td>

</tr><tr>
<tbody><tr>
<td class="embedded"><form method="get" action="ipcheck.php"><input type="submit" value="Duplicate IPs" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="adduser.php"><input type="submit" value="Add User" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="makepoll.php"><input type="submit" value="Poll Manager" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="activity.php"><input type="submit" value="Mod Log" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="changeusername.php"><input type="submit" value="Rename User" style="height: 25px; width: 100px"></form></td>

<tr>

</tr>
</tbody></table>
<br>

</td></tr></tbody></table>

<?php }?>
<?phpif (get_user_class() >= UC_SYSOP){?>

<h2>SysOp Tools</h2>

<table width="100%" border="1" cellspacing="0" cellpadding="10"><tbody><tr><td>

<br>
<table width="500" cellspacing="3">
<tbody><tr>
<td class="embedded"></td>

</tr>

</tbody></table>
<table width="500" cellspacing="10" align="center">
<tbody><tr>
<td class="embedded"><form method="get" action="spam.php"><input type="submit" value="Message Spy" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="announcement.php"><input type="submit" value="Announce Manage" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="EMPTY.php"><input type="submit" value="EMPTY" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="EMPTY.php"><input type="submit" value="EMPTY" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="EMPTY.php"><input type="submit" value="EMPTY" style="height: 25px; width: 100px"></form></td>

</tr><tr>
<tbody><tr>
<td class="embedded"><form method="get" action="EMPTY.php"><input type="submit" value="EMPTY" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="EMPTY.php"><input type="submit" value="EMPTY" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="EMPTY.php"><input type="submit" value="EMPTY" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="EMPTY.php"><input type="submit" value="EMPTY" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="EMPTY.php"><input type="submit" value="EMPTY" style="height: 25px; width: 100px"></form></td>

<tr>
<td class="embedded"><form method="get" action="EMPTY.php"><input type="submit" value="EMPTY" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="EMPTY.php"><input type="submit" value="EMPTY" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="EMPTY.php"><input type="submit" value="EMPTY" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="EMPTY.php"><input type="submit" value="EMPTY" style="height: 25px; width: 100px"></form></td>
<td class="embedded"><form method="get" action="EMPTY.php"><input type="submit" value="EMPTY" style="height: 25px; width: 100px"></form></td>

</tr>
</tbody></table>
<br>

</td></tr></tbody></table>

<?php }?>
<?php

stdfoot
();

?>