• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

[GESIOR ACC] Report-BUG System 2 (Updated)

Dark ShaoOz

Member
Joined
Apr 19, 2009
Messages
80
Reaction score
5
Hello, If you are new and you dont have the first part of this system, please go and have a look to this page (you need it: http://otland.net/threads/gesior-acc-report-bug-system-advanced.211005/
http://otland.net/threads/gesior-acc-report-bug-system-advanced.211005/
I updated the adminreport.php, change for this script:

Code:
<?PHP
if($group_id_of_acc_logged >= $config['site']['access_admin_panel']) {
    $main_content .= '<center><h2><font color=red>Reports List</font></h2></center><br /><br />
<center><table border="0" cellspacing="1" cellpadding="4" width="100%">
    <tr bgcolor="'.$config['site']['vdarkborder'].'">
        <td width="5%"><b><font color=white><center>#</font></center></b></td>
        <td width="10%"><b><font color=white><center>Name</center></b></font></td>
        <td width="20%"><b><font color=white><center>Position</center></b></font></td>
        <td width="40%"><b><font color=white><center>Description</center></b></font></td>
        <td width="20%"><b><font color=white><center>Date</center></b></font></td>
    </tr>';
$i = 0;
foreach($SQL->query('SELECT id, name, posx, posy, posz, report_description, date FROM player_reports WHERE fixed = 0 ORDER BY id DESC limit 100;') as $report)
{
    $i++;
    $main_content .= '<tr bgcolor="' . (is_int($i / 2) ? $config['site']['lightborder'] : $config['site']['darkborder']). '">
        <td>         
            <center>'.$report['id'].'</center>
        </td>
        <td>         
            <center><a href=?subtopic=characters&name='.$report['name'].'>'.$report['name'].'</a></center>
        </td>
        <td>
            <center>'.$report['posx'].', '.$report['posy'].', '.$report['posz'].'</center>
        </td>
        <td>
            <center>'.$report['report_description'].'</center>
        </td>
        <td>
            <center>'.$report['date'].'</center>
        </td>
    </tr>';
}
$main_content .='
</table>
    <a href="?subtopic=adminreport&action=reward">Reward Players for reporting.</a>';
if($action == "reward") {
        $player = stripslashes(ucwords(strtolower(trim($_REQUEST['character']))));
        $points = $_POST['points'];
        if(empty($player)) {
            $main_content .= '<form action="" method="post"><B>Enter Character Name:</B><input type="textbox" name="character"><br>
                <B>Enter Points Amount:</B><input type="textbox" name="points"><br><br><input type="submit" value="Submit">
                </form></center><form action="?subtopic=adminreport" method="post" ><input name="submit" type="submit" value="Close" title="Close"/></form>';
        } else {
            $player_data = $SQL->query("SELECT * FROM `players` WHERE `name` = '".$player."';")->fetch();
            $SQL->query("UPDATE `accounts` SET `premium_points` = `premium_points` + '".$points."' WHERE `id` = '".$player_data['account_id']."'");
            $main_content .= '<b><center>'.$points.' Premium Points added to the account of <i>'.$player.'</i> !</b></center><br>
                <form action="?subtopic=adminreport" method="post" ><input name="submit" type="submit" value="Close" title="Close"/></form>';
        }
    }
$main_content .='
</table>
<br>
    <a href="?subtopic=reportadmin&action=fixed">Select Fixed Bugs.</a>';
if($action == "fixed") {
        $player = stripslashes(ucwords(strtolower(trim($_REQUEST['character']))));
        $fixed = $_POST['fixed'];
        if(empty($fixed)) {
            $main_content .= '<form action="" method="post">
                <B>Enter report #:</B><input type="textbox" name="fixed"><br><br><input type="submit" value="Submit">
                </form></center><form action="?subtopic=adminreport" method="post" ><input name="submit" type="submit" value="Close" title="Close"/></form>';
        } else {
            $SQL->query("UPDATE `player_reports` SET `fixed` = '1' WHERE `id` = '".$fixed."'");
           
            $main_content .= '<b><center>Report #'.$fixed.' listed in Fixed List!</b></center><br>
                <form action="?subtopic=adminreport" method="post" ><input name="submit" type="submit" value="Close" title="Close"/></form>';
        }
    }
} else {
    $main_content .= 'Sorry, you have not the rights to access this page.';
}
?>
For admin, now you can set the reports to fixed in the last link "Select Fixed bugs", with that:
Now players can see if the reports are fixed, if they are fixed they will appear on another section, here is the script for that section, you have to add it into ur htdocs folder or pages folder:
Code:
<?PHP
    $main_content .= '<center><h2><font color=red>Fixed Bugs</font></h2></center><br /><br />
<center><table border="0" cellspacing="1" cellpadding="4" width="100%">
    <tr bgcolor="'.$config['site']['vdarkborder'].'">
        <td width="5%"><b><font color=white><center>#</font></center></b></td>
        <td width="10%"><b><font color=white><center>Name</center></b></font></td>
        <td width="50%"><b><font color=white><center>Description</center></b></font></td>
        <td width="25%"><b><font color=white><center>Date of Report</center></b></font></td>
    </tr>';
$i = 0;
foreach($SQL->query('SELECT id, name, report_description, date FROM player_reports WHERE fixed = 1 ORDER BY id DESC limit 20;') as $report)
{
    $i++;
    $main_content .= '<tr bgcolor="' . (is_int($i / 2) ? $config['site']['lightborder'] : $config['site']['darkborder']). '">
        <td>         
            <center>'.$i.'</center>
        </td>
        <td>         
            <center><a href=?subtopic=characters&name='.$report['name'].'>'.$report['name'].'</a></center>
        </td>
        <td>
            <center>'.$report['report_description'].'</center>
        </td>
        <td>
            <center>'.$report['date'].'</center>
        </td>
    </tr>';
}
$main_content .='
</table>';
?>
It will look like this:

330fh8w.png


And the last thing, you have to alter a table into your database, log into your phpmyadmin, then select your database, the click on your table "player_reports" and then on the top click on SQL and it will be a text box, add this and the click ok:

Code:
ALTER TABLE `player_reports` ADD `fixed` INT(2) NOT NULL ;

And now all you have to do it's fix the bugs that players report, then enter the adminreport section, when you fix one of them, just see the Report # listed in the list and then go to the buttom, click on Select Fixed Bug, and write the Report #, and the report will be deleted from the adminreport section and now it'll be on the fixedbugs section.
I hope you like it!
Thanks
Script 100% made by Dark Shaooz
 
When i select "Select Fixed Bugs" it appears to me:

2nt94b5.png


So nothing.

Help please? ^^
 
HELP ME! i report bugs but when i got to report page,
No reports submitted.
 
Back
Top