* This is the VOP Radius mailing list *
Just wanted to give people a heads up on the PHP Stats system I mentioned last week. I have ported most of my code over to a PHP class. Currently it is able to parse all the info into a nice php based array. I just need to write up some code to generate an html table and it will be all set. I have included a sample of the usage and a partial dump of the main table.

Here is the index.php file.

-----------------------------
include("libras/libras.php");

$a = new rasstat;
if ($debug) { $a->debug = 1; }
$a->hostname = "XXX.14.231.2";
$a->snmpid = "XXX";
$a->num_lines = 115;
$a->name = "Example City";

echo "Current Usage is " . $a->current_usage() . "<br>";
echo "Current Uptime is " . $a->uptime() . "<br>";
echo "Usage Table<br>";
echo $a->generate();
-----------------------------

And what it generates.

Current Usage is 50 of 115
Current Uptime is 34:22:25:11.13
Usage Table

Count: 60
Array
(
[0] => Array
(
[ptr] => 197111443
[username] => "newatkins"
[time] => 12:2:53:17.15
[ip] => XXX.14.231.245
[phone] => "XXX4498238"
[line] => ISDN
)

[1] => Array
(
[ptr] => 214010912
[username] => "gmnhbh"
[time] => 10:3:56:42.46
[ip] => XXX.14.231.244
[phone] => "XXX4418633"
[line] => ISDN
)

[2] => Array
(
[ptr] => 214011112
[username] => "gmnhbh"
[time] => 10:3:56:40.46
[ip] => XXX.14.231.244
[phone] => "XXX4418759"
[line] => ISDN
)





**
To leave this list, send an email to [EMAIL PROTECTED]
and put the word "LEAVE" in the BODY of the email.

Reply via email to