You are here

function fblikebutton_menu in Facebook Like Button 7.2

Same name and namespace in other branches
  1. 6.2 fblikebutton.module \fblikebutton_menu()
  2. 6 fblikebutton.module \fblikebutton_menu()
  3. 7 fblikebutton.module \fblikebutton_menu()

Implements of hook_menu().

File

./fblikebutton.module, line 14
Adds Facebook's "Like" button to each selected node type. Adds a block with a global static value where users can "Like" the URL set by admins.

Code

function fblikebutton_menu() {
  $items['admin/config/fblikebutton'] = array(
    'title' => 'FB Like Button',
    'description' => 'Configure the Facebook Like button',
    'page callback' => 'system_admin_menu_block_page',
    'access arguments' => array(
      'administer fblikebutton',
    ),
    'position' => 'right',
    'weight' => -20,
    'type' => MENU_NORMAL_ITEM,
    'file' => 'system.admin.inc',
    'file path' => drupal_get_path('module', 'system'),
  );
  $items['admin/config/fblikebutton/dynamic'] = array(
    'title' => 'Dynamic Like button settings',
    'description' => 'Configure the settings for the Like button as it appears on individual nodes (liking that node).',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'fblikebutton_dynamic_settings',
    ),
    'access arguments' => array(
      'administer fblikebutton',
    ),
    'type' => MENU_NORMAL_ITEM,
    'file' => 'fblikebutton.admin.inc',
    'weight' => 0,
  );
  $items['admin/config/fblikebutton/static'] = array(
    'title' => 'Static Like button settings',
    'description' => 'Configure the settings for the static Like button as it appears in the block (liking a given url). Use this to like for example your Facebook fanpage.',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'fblikebutton_static_settings',
    ),
    'access arguments' => array(
      'administer fblikebutton block',
    ),
    'type' => MENU_NORMAL_ITEM,
    'file' => 'fblikebutton.admin.inc',
    'weight' => 1,
  );
  return $items;
}