tobyrice01 Posted May 20, 2015 Report Share Posted May 20, 2015 In my VA, Fly American Virtual, the VA stats show the TOTAL number of pilots in the VA. I have all active pilots in a group, and then all the inactive or retired pilots in another group, so that everything is organized. How do I set the VA stats "total pilots" to the number of pilots in the group "Active Pilots" that I have? For reference, here is what "Stats" box I'm talking about: <h3>Statistics</h3> Total Pilots: <?php echo StatsData::PilotCount(); ?> <br /> Total Flights: <?php echo number_format(StatsData::TotalFlights()); ?><br /> Total Flights Today: <?php echo StatsData::totalflightstoday(); ?><br /> Total Flight Hours: <?php echo number_format(StatsData::TotalHours(), 0); ?> hrs<br /> Total Pax Carried: <?php echo number_format(StatsData::totalpaxcarried()); ?><br /> Total Fuel Burned: <?php echo number_format(StatsData::totalfuelburned(), 0); ?> lbs<br /> Total Flight Miles: <?php echo number_format(StatsData::totalmilesflown()); ?> nm<br /> Total Schedules: <?php echo StatsData::TotalSchedules(); ?><br /> I don't speak very well php... I just finished my course in HTML and CSS, but php still presents itself to be out of my expertise. Any help? Quote Link to comment Share on other sites More sharing options...
Sava Posted May 20, 2015 Report Share Posted May 20, 2015 <?php echo count(PilotGroups::getUsersInGroup('1')); ?> Change 1 to the ID of the Active pilot group Quote Link to comment Share on other sites More sharing options...
tobyrice01 Posted May 20, 2015 Author Report Share Posted May 20, 2015 Thanks, works great! Appreciate it. Quote Link to comment Share on other sites More sharing options...
Sava Posted May 23, 2015 Report Share Posted May 23, 2015 You are welcome:) Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.