function blog_user_view
blog_user_view($account)
Implements hook_user_view().
File
- modules/blog/blog.module, line 24
- Enables multi-user blogs.
Code
function blog_user_view($account) { if (user_access('create blog content', $account)) { $account->content['summary']['blog'] = array( '#type' => 'user_profile_item', '#title' => t('Blog'), // l() escapes the attributes, so we should not escape !username here. '#markup' => l(t('View recent blog entries'), "blog/$account->uid", array('attributes' => array('title' => t("Read !username's latest blog entries.", array('!username' => format_username($account)))))), '#attributes' => array('class' => array('blog')), ); } }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/modules!blog!blog.module/function/blog_user_view/7.x