function blog_user in Drupal 5
Same name and namespace in other branches
- 4 modules/blog.module \blog_user()
- 6 modules/blog/blog.module \blog_user()
Implementation of hook_user().
File
- modules/
blog/ blog.module, line 48 - Enables keeping an easily and regularly updated web page or a blog.
Code
function blog_user($type, &$edit, &$user) {
if ($type == 'view' && user_access('edit own blog', $user)) {
$items['blog'] = array(
'title' => t('Blog'),
'value' => l(t('View recent blog entries'), "blog/{$user->uid}", array(
'title' => t("Read @username's latest blog entries.", array(
'@username' => $user->name,
)),
)),
'class' => 'blog',
);
return array(
t('History') => $items,
);
}
}