function user_block_info
Implements hook_block_info().
File
-
modules/
user/ user.module, line 1385
Code
function user_block_info() {
global $user;
$blocks['login']['info'] = t('User login');
// Not worth caching.
$blocks['login']['cache'] = DRUPAL_NO_CACHE;
$blocks['new']['info'] = t('Who\'s new');
$blocks['new']['properties']['administrative'] = TRUE;
// Too dynamic to cache.
$blocks['online']['info'] = t('Who\'s online');
$blocks['online']['cache'] = DRUPAL_NO_CACHE;
$blocks['online']['properties']['administrative'] = TRUE;
return $blocks;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.