function media_unsplash_menu in Media Unsplash 7
Implements hook_menu().
File
- ./
media_unsplash.module, line 11 - Provides definition for unsplash media integration.
Code
function media_unsplash_menu() {
$items['admin/config/media/unsplash'] = array(
'title' => 'Unsplash Media',
'description' => 'Settings for media_unsplash module',
'page callback' => 'drupal_get_form',
'page arguments' => array(
'media_unsplash_admin',
),
'access arguments' => array(
'administer media browser',
),
'type' => MENU_NORMAL_ITEM,
'file' => 'media_unsplash.admin.inc',
);
$items['file/add/unsplash'] = array(
'title' => 'Unsplash',
'description' => 'Add images from unsplash to your media library.',
'page callback' => 'drupal_get_form',
'page arguments' => array(
'media_unsplash_external',
),
'access arguments' => array(
'access media browser',
),
'type' => MENU_LOCAL_TASK,
'file' => 'file_entity.pages.inc',
'file path' => drupal_get_path('module', 'file_entity'),
);
$items['unsplash/ajax'] = array(
'title' => 'Unsplash',
'page callback' => 'media_unsplash_ajax',
'theme callback' => 'ajax_base_page_theme',
'delivery callback' => 'ajax_deliver',
'access callback' => TRUE,
'description' => 'Unsplash callback for images loading.',
'type' => MENU_CALLBACK,
'file' => 'media_unsplash.pages.inc',
);
return $items;
}