You are here

function blog_menu in Drupal 7

Same name and namespace in other branches
  1. 4 modules/blog.module \blog_menu()
  2. 5 modules/blog/blog.module \blog_menu()
  3. 6 modules/blog/blog.module \blog_menu()

Implements hook_menu().

File

modules/blog/blog.module, line 101
Enables multi-user blogs.

Code

function blog_menu() {
  $items['blog'] = array(
    'title' => 'Blogs',
    'page callback' => 'blog_page_last',
    'access arguments' => array(
      'access content',
    ),
    'type' => MENU_SUGGESTED_ITEM,
    'file' => 'blog.pages.inc',
  );
  $items['blog/%user_uid_optional'] = array(
    'title' => 'My blog',
    'page callback' => 'blog_page_user',
    'page arguments' => array(
      1,
    ),
    'access callback' => 'blog_page_user_access',
    'access arguments' => array(
      1,
    ),
    'file' => 'blog.pages.inc',
  );
  $items['blog/%user/feed'] = array(
    'title' => 'Blogs',
    'page callback' => 'blog_feed_user',
    'page arguments' => array(
      1,
    ),
    'access callback' => 'blog_page_user_access',
    'access arguments' => array(
      1,
    ),
    'type' => MENU_CALLBACK,
    'file' => 'blog.pages.inc',
  );
  $items['blog/feed'] = array(
    'title' => 'Blogs',
    'page callback' => 'blog_feed_last',
    'access arguments' => array(
      'access content',
    ),
    'type' => MENU_CALLBACK,
    'file' => 'blog.pages.inc',
  );
  return $items;
}