You are here

function comment_menu in Drupal 6

Same name and namespace in other branches
  1. 4 modules/comment.module \comment_menu()
  2. 5 modules/comment/comment.module \comment_menu()
  3. 7 modules/comment/comment.module \comment_menu()

Implementation of hook_menu().

File

modules/comment/comment.module, line 195
Enables users to comment on published content.

Code

function comment_menu() {
  $items['admin/content/comment'] = array(
    'title' => 'Comments',
    'description' => 'List and edit site comments and the comment moderation queue.',
    'page callback' => 'comment_admin',
    'access arguments' => array(
      'administer comments',
    ),
    'file' => 'comment.admin.inc',
  );

  // Tabs:
  $items['admin/content/comment/new'] = array(
    'title' => 'Published comments',
    'type' => MENU_DEFAULT_LOCAL_TASK,
    'weight' => -10,
  );
  $items['admin/content/comment/approval'] = array(
    'title' => 'Approval queue',
    'page arguments' => array(
      'approval',
    ),
    'access arguments' => array(
      'administer comments',
    ),
    'type' => MENU_LOCAL_TASK,
    'file' => 'comment.admin.inc',
  );
  $items['comment/delete'] = array(
    'title' => 'Delete comment',
    'page callback' => 'comment_delete',
    'access arguments' => array(
      'administer comments',
    ),
    'type' => MENU_CALLBACK,
    'file' => 'comment.admin.inc',
  );
  $items['comment/edit'] = array(
    'title' => 'Edit comment',
    'page callback' => 'comment_edit',
    'access arguments' => array(
      'post comments',
    ),
    'type' => MENU_CALLBACK,
    'file' => 'comment.pages.inc',
  );
  $items['comment/reply/%node'] = array(
    'title' => 'Reply to comment',
    'page callback' => 'comment_reply',
    'page arguments' => array(
      2,
    ),
    'access callback' => 'node_access',
    'access arguments' => array(
      'view',
      2,
    ),
    'type' => MENU_CALLBACK,
    'file' => 'comment.pages.inc',
  );
  return $items;
}