<?
if ($auth_sid) {
  if ($myauth['id']) {
    sqlexec("update auth_users set lastvisit=now() where userid=".$myauth['id']);
  }
}

if (!$NOLAYOUT) {
appfooter();
#syndfooter($siteid);
}

/*
$ts=date('Y-m-d H:i:s',mktime()-900);
$res=sqlexec("select distinct name from auth_users where 
lastvisit>'$ts'");
$users=array();
while($row=sqlgetrow($res)) {
if ($row['name']!='') {
  $users[]=$row['name'];
} else {
  $users[]='[unknown]';
}
}
$cnt=count($users);
echo "<h6>There has been $cnt users: ".join(',',$users)." on this site 
in the last 15 minutes. ";
*/

if ($conn) {
//if (useringroup(array('administrator'))) $DEBUG_LEVEL=1;
sqlclose($conn);
}
$diff=get_timer($starttime);
echo "Took $diff secs to generate</h6>\n";
?>
