AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Plugin/Gameplay Ideas and Requests (https://forums.alliedmods.net/forumdisplay.php?f=60)
-   -   Calladmin WEBSITE (https://forums.alliedmods.net/showthread.php?t=303568)

AceNetworks 12-12-2017 14:06

Calladmin WEBSITE
 
Is it possible do to a calladmin website? which shows new reports and old in a list?

SZOKOZ 12-12-2017 19:31

Re: Calladmin WEBSITE
 
Indeed it is possible.

B3none 12-13-2017 07:44

Re: Calladmin WEBSITE
 
Yes, this is certainly do-able.
I'll make one for a cheap price. :)

mlov420 12-13-2017 08:11

Re: Calladmin WEBSITE
 
Here you go bud. It is extremely basic, put it together in about 10 minutes just now to give you a starting point, you can style it and adjust it to your liking. Just copy this whole thing to notepad, adjust the Database settings to your database, save as whatever.php, and upload to your site.

Uses PHP7. If you're on an older version of PHP, you will need to change any instances of 'mysqli' to 'mysql'. Good luck <3

Here is a demo of the code beloww: http://raidboss.org/calladmin.php

Code:

<!DOCTYPE html>
<html lang="en">

        <head>
                <!-- Bootstrap 4 Beta 2 -->
                <link async rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta.2/css/bootstrap.min.css" integrity="sha384-PsH8R72JQ3SOdhVi3uxftmaW6Vc51MKb0q5P2rRUpPvrszuE4W1povHYgTpBfshb" crossorigin="anonymous">
        </head>

        <body>
                <div class="col-md-12">
                        <table class="table table-sm">
                                <tr class="text-center" style="margin-bottom:15px"><td colspan="7">Call Admin Requests</td></tr>
                               
                                <tr>
                                        <td>Server IP</td>
                                        <td>Target Name</td>
                                        <td>Target SteamID</td>
                                        <td>Reason</td>
                                        <td>Reporter Name</td>
                                        <td>Reporter SteamID</td>
                                        <td>Date Reported</td>
                                </tr>
                               
                                <?
                                        //DB Config
                                        $servername = "yourHostIP";
                                        $username = "yourDBUserName";
                                        $password = "yourDBPassword";
                                        $db = "yourCallAdminDB";


                                        // Create connection
                                        $conn = mysqli_connect($servername, $username, $password, $db);
                                        // Check connection
                                        if (!$conn) {
                                                die("Connection failed: " . mysqli_connect_error());
                                        }
                                       
                                        //Get all info from calladmin db (callID, serverIP, serverPort, serverName, serverKey, targetName, targetID, targetReason, [cont...])
                                        // [cont...] clientName, clientID, callHandled, reportedAt)
                                        $callAdmin_query = mysqli_query($conn, "SELECT * FROM calladmin");
                                        while($callAdmin = mysqli_fetch_assoc($callAdmin_query)){
                                ?>
                               
                                <tr style="font-size:12px">
                                        <td><?=$callAdmin['serverIP'];?></td>
                                        <td><?=$callAdmin['targetName'];?></td>
                                        <td><?=$callAdmin['targetID'];?></td>
                                        <td><?=$callAdmin['targetReason'];?></td>
                                        <td><?=$callAdmin['clientName'];?></td>
                                        <td><?=$callAdmin['clientID'];?></td>
                                        <td><?=date("F j, Y, g:i a", $callAdmin['reportedAt']);?></td>
                                </tr>
                               
                                <? } ?>
                                <? mysqli_close($conn); ?>
                        </table>
                </div>
        </body>
</html>


B3none 12-13-2017 08:56

Re: Calladmin WEBSITE
 
I wasn't going to do it like that! :D I would have made you a Silex App for it.

AceNetworks 12-13-2017 09:52

Re: Calladmin WEBSITE
 
Quote:

Originally Posted by mlov420 (Post 2565959)
Here you go bud. It is extremely basic, put it together in about 10 minutes just now to give you a starting point, you can style it and adjust it to your liking. Just copy this whole thing to notepad, adjust the Database settings to your database, save as whatever.php, and upload to your site.

Uses PHP7. If you're on an older version of PHP, you will need to change any instances of 'mysqli' to 'mysql'. Good luck <3

Here is a demo of the code beloww: http://raidboss.org/calladmin.php

Code:

<!DOCTYPE html>
<html lang="en">

        <head>
                <!-- Bootstrap 4 Beta 2 -->
                <link async rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta.2/css/bootstrap.min.css" integrity="sha384-PsH8R72JQ3SOdhVi3uxftmaW6Vc51MKb0q5P2rRUpPvrszuE4W1povHYgTpBfshb" crossorigin="anonymous">
        </head>

        <body>
                <div class="col-md-12">
                        <table class="table table-sm">
                                <tr class="text-center" style="margin-bottom:15px"><td colspan="7">Call Admin Requests</td></tr>
                               
                                <tr>
                                        <td>Server IP</td>
                                        <td>Target Name</td>
                                        <td>Target SteamID</td>
                                        <td>Reason</td>
                                        <td>Reporter Name</td>
                                        <td>Reporter SteamID</td>
                                        <td>Date Reported</td>
                                </tr>
                               
                                <?
                                        //DB Config
                                        $servername = "yourHostIP";
                                        $username = "yourDBUserName";
                                        $password = "yourDBPassword";
                                        $db = "yourCallAdminDB";


                                        // Create connection
                                        $conn = mysqli_connect($servername, $username, $password, $db);
                                        // Check connection
                                        if (!$conn) {
                                                die("Connection failed: " . mysqli_connect_error());
                                        }
                                       
                                        //Get all info from calladmin db (callID, serverIP, serverPort, serverName, serverKey, targetName, targetID, targetReason, [cont...])
                                        // [cont...] clientName, clientID, callHandled, reportedAt)
                                        $callAdmin_query = mysqli_query($conn, "SELECT * FROM calladmin");
                                        while($callAdmin = mysqli_fetch_assoc($callAdmin_query)){
                                ?>
                               
                                <tr style="font-size:12px">
                                        <td><?=$callAdmin['serverIP'];?></td>
                                        <td><?=$callAdmin['targetName'];?></td>
                                        <td><?=$callAdmin['targetID'];?></td>
                                        <td><?=$callAdmin['targetReason'];?></td>
                                        <td><?=$callAdmin['clientName'];?></td>
                                        <td><?=$callAdmin['clientID'];?></td>
                                        <td><?=date("F j, Y, g:i a", $callAdmin['reportedAt']);?></td>
                                </tr>
                               
                                <? } ?>
                                <? mysqli_close($conn); ?>
                        </table>
                </div>
        </body>
</html>



thank you but i need it more advanced :D

AceNetworks 12-13-2017 09:53

Re: Calladmin WEBSITE
 
Quote:

Originally Posted by b3none (Post 2565968)
I wasn't going to do it like that! :D I would have made you a Silex App for it.

Added you on Steam

mlov420 12-13-2017 09:56

Re: Calladmin WEBSITE
 
Quote:

Originally Posted by b3none (Post 2565968)
I wasn't going to do it like that! :D I would have made you a Silex App for it.

That's cool if he wants to pay for something. I was just offering a quick solution for the lad.

Quote:

thank you but i need it more advanced
You're welcome. It wasn't meant to be a final solution, it was an example you could build off easily without having to pay for. What more would you be looking for anyway? Everything you need is already built into the plugin and this displays those calls descending by most recent. Maybe add some a count limit and pagination, some styling of your own? I just don't know what advanced features could go into this?

AceNetworks 12-13-2017 10:01

Re: Calladmin WEBSITE
 
Quote:

Originally Posted by mlov420 (Post 2565977)
That's cool if he wants to pay for something. I was just offering a quick solution for the lad.



You're welcome. It wasn't meant to be a final solution, it was an example you could build off easily without having to pay for. What more would you be looking for anyway? Everything you need is already built into the plugin and this displays those calls descending by most recent. Maybe add some a count limit and pagination, some styling of your own? I just don't know what advanced features could go into this?


paulo_crash 12-15-2017 15:41

Re: Calladmin WEBSITE
 
I found the idea interesting, if after finalized can disclose how it was and the price to buy thank you, I would like to purchase.


All times are GMT -4. The time now is 02:19.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.