Aaron Posted December 5, 2011 Report Posted December 5, 2011 Does someone have the code to display the names and/or callsigns of users logged on the site. Thanks Quote
Aaron Posted December 5, 2011 Author Report Posted December 5, 2011 This is what I tryed, but it doesn't work properly. <?php if ($usersonline=="0") { ?> echo "There are no users currently online" <?php } else foreach($useronline as $pilot) { ?> <p><a href="<?php echo url('/profile/view/'.$pilot->pilotid);?>"><?php echo PilotData::GetPilotCode($pilot->code, $pilot->pilotid). ' ' .$pilot->firstname . ' ' . $pilot->lastname?></a></p> <?php } ?> <?php echo count($guestsonline);?> guest(s) online in the past <?php echo Config::Get('USERS_ONLINE_TIME')?> minutes.</i></p> Quote
Aaron Posted December 5, 2011 Author Report Posted December 5, 2011 figured it out. in the foreach ($usersonline as $pilot), the 's' was missing. It works now. Quote
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.