PHP Classes
elePHPant
Icontem

File: testphpc.php

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Pierre FAUQUE  >  PHP Classes Stats Class  >  testphpc.php  >  Download  
File: testphpc.php
Role: Example script
Content type: text/plain
Description: Script for test
Class: PHP Classes Stats Class
Get package download statistics from PHPClasses
Author: By
Last change:
Date: 8 years ago
Size: 725 bytes
 

Contents

Class file image Download
<html>

<head><title>Package stats</title></head>

<body>
<pre>
<?
if(!$submit)
{
    echo
"<form method='post' action='$PHP_SELF'>\n";
    echo
"Package n <input type='text' name='np' size='6'>";
    echo
"<input type='submit' name='submit' value='OK'>\n";
    echo
"</form>\n";
}
else
{
    require(
"class.phpcstats.php");
   
$pack = new phpcstats($np);
   
$link = "<a href='".$pack->showurl()."' target='_new'>Verify</a>\n";
    echo
$pack->showurl() . " " . $link;
    echo
"All time users: " . $pack->stats["atu"] . "\n";
    echo
" All time rank: " . $pack->stats["atr"] . "\n";
    echo
" Week users: " . $pack->stats["wu"] . "\n";
    echo
" Week rank: " . $pack->stats["wr"] . "\n";
}
?>
</pre>
</body>
</html>