Vatsim Statistics

A module for phpVMS to view Vatsim Live Statistics


Install:

  1. Download at Github.

  2. Upload to your site in folder’s order.

  3. Access using the following code:

    <?php echo url('/vatsimstats') ;?>
  4. Enjoy!

*The <div> element refreshes every 3 second which can be modified to desired time.

*This is for phpVMS 5.5x version by Simpilot.


Demo:

At my website http://www.parkho.ir


Support:

Use “Contact Me” at my website http://www.parkho.ir

Screenshot:

Use the following code anywhere you want. You’ll just need to position the <div>:

<?php
$json = file_get_contents("https://stats.vatsim.net/user_count_json.php");
$data = json_decode($json, true);
$pilots = $data['pilots'];
$controllers = $data['controllers'];
$atis = $data['atis'];
$observers = $data['observers'];
$supervisors = $data['supervisors'];
$total = $data['total'];
?>
<h3 style="margin-left: 80px; margin-top: 75px;">Vatsim Online Users</h3>
<div id="vs" style="border: solid 3px; padding: 25px; border-radius: 5px;" class="container">
<ul class="blocklist">
 <li>Pilots : <?php echo $pilots;?></li>
 <li>Controllers : <?php echo $controllers;?></li>
 <li>Atis : <?php echo $atis;?></li>
 <li>Observers : <?php echo $observers;?></li>
 <li>Supervisors : <?php echo $supervisors;?></li>
 <li>Total : <?php echo $total;?></li>	   
</ul>
</div>
<script type="text/javascript">
function liveflight(){
 $("#vs").load(location.href + " #vs>*", "");
}
setInterval(function(){liveflight()}, 3000);
</script>

Works just awesome. Thank you very much for this module. Hoping for a similar module for IVAO too

Looks nice! I will have to give it a try this evening.

Is it possible to add your airline into the stats? example

ALA Pilots Online: 12

Is it possible to add your airline into the stats? example

ALA Pilots Online: 12

I’ll look into it.

I’ll look into it.

Thanks!

Thanks!

Unfortunately the json page used, doesn’t provide specific airline status and I couldn’t find a solid API for VATSIM statistics, so the answer to your Q is NO!