Advertisement
denahv

Untitled

Sep 9th, 2011
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.11 KB | None | 0 0
  1. <?
  2.     include("config.php");
  3.     include("commonfunctions.php");
  4.     $irpg_page_title = "Player Info";
  5.     include("header.php");
  6. ?>
  7.  
  8.   <h1>Players</h1>
  9.   <h2>Pick a player to view</h2>
  10.   <p class="small">[gray=offline]</p>
  11.   <ol>
  12. <?php
  13.     $file = file($irpg_db);
  14.     unset($file[0]);
  15.     usort($file, 'cmp_level_desc');
  16.     foreach ($file as $line) {
  17.         list($user,,,$level,$class,$secs,,,$online) = explode("\t",trim($line));
  18.  
  19.         $class = htmlentities($class);
  20.         $next_level = duration($secs);
  21.  
  22.         print "    <li".(!$online?" class=\"offline\"":"")."><a".
  23.               (!$online?" class=\"offline\"":"").
  24.               " href=\"playerview.php?player=".urlencode($user).
  25.               "\">".htmlentities($user).
  26.               "</a>, the level $level $class. Next level in $next_level.</li>\n";
  27.  
  28.     }
  29. ?>
  30.   </ol>
  31.   <p>For a script to view player stats from a terminal, try <a
  32.   href="idlerpg-adv.txt">this</a> perl script by
  33.   <a href="mailto:daxxar@mental.mine.nu">daxxar</a>.</p>
  34.  
  35.   <p>See player stats in <a href="db.php">table format</a>.</p>
  36.  
  37. <?include("footer.php")?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement