function admin_menu_get_user_count

cis7 admin_menu.module admin_menu_get_user_count()
cle7 admin_menu.module admin_menu_get_user_count()
elmsmedia7 admin_menu.module admin_menu_get_user_count()
icor7 admin_menu.module admin_menu_get_user_count()
meedjum_blog7 admin_menu.module admin_menu_get_user_count()
mooc7 admin_menu.module admin_menu_get_user_count()

Return count of online anonymous/authenticated users.

See also

user_block(), user.module

3 calls to admin_menu_get_user_count()
admin_menu_admin_menu_replacements in sites/all/modules/ulmus/admin_menu/admin_menu.module
Implements hook_admin_menu_replacements().
admin_menu_links_users in sites/all/modules/ulmus/admin_menu/admin_menu.inc
Builds user counter.
hook_admin_menu_replacements in sites/all/modules/ulmus/admin_menu/admin_menu.api.php
Return content to be replace via JS in the cached menu output.

File

sites/all/modules/ulmus/admin_menu/admin_menu.module, line 416
Render an administrative menu as a dropdown menu at the top of the window.

Code

function admin_menu_get_user_count() {
  $interval = REQUEST_TIME - variable_get('user_block_seconds_online', 900);
  $count_anon = admin_menu_session_count($interval, TRUE);
  $count_auth = admin_menu_session_count($interval, FALSE);

  return t('@count-anon / @count-auth', array('@count-anon' => $count_anon, '@count-auth' => $count_auth));
}
Error | ELMSLN API

Error

×

Error message

  • Warning: Cannot modify header information - headers already sent by (output started at /var/www/html/elmsln_community/api.elmsln.org/includes/common.inc:2791) in drupal_send_headers() (line 1499 of /var/www/html/elmsln_community/api.elmsln.org/includes/bootstrap.inc).
  • Error: Call to undefined function apc_delete() in DrupalAPCCache->clear() (line 289 of /var/www/html/elmsln_community/api.elmsln.org/sites/all/modules/apc/drupal_apc_cache.inc).
The website encountered an unexpected error. Please try again later.