1 file.module file_menu()

Implements hook_menu().

File

core/modules/file/file.module, line 71
Defines a "managed_file" Form API field and a "file" field for Field module.

Code

function file_menu() {
  $items = array();

  $items['file/ajax'] = array(
    'page callback' => 'file_ajax_upload',
    'delivery callback' => 'ajax_deliver',
    'access arguments' => array('access content'),
    'theme callback' => 'ajax_base_page_theme',
    'type' => MENU_CALLBACK,
  );

  // @deprecated. Remove in Backdrop 2.0.
  $items['file/progress'] = array(
    'page callback' => 'file_ajax_progress',
    'delivery callback' => 'backdrop_json_deliver',
    'access arguments' => array('access content'),
    'theme callback' => 'ajax_base_page_theme',
    'type' => MENU_CALLBACK,
  );

  $items['file/%file/manage'] = array(
    'title' => 'Manage',
    'page callback' => 'backdrop_get_form',
    'page arguments' => array('file_manage_form', 1),
    'access arguments' => array('manage files'),
    'weight' => 0,
    'type' => MENU_CALLBACK,
    'file' => 'file.pages.inc',
  );
  $items['file/%file/delete'] = array(
    'title' => 'Delete',
    'page callback' => 'backdrop_get_form',
    'page arguments' => array('file_delete_form', 1),
    'access arguments' => array('delete files'),
    'weight' => 1,
    'type' => MENU_CALLBACK,
    'file' => 'file.pages.inc',
  );

  $items['admin/content/files/delete'] = array(
    'title' => 'Confirm deleting multiple files',
    'type' => MENU_VISIBLE_IN_BREADCRUMB,
    'page callback' => 'backdrop_get_form',
    'page arguments' => array('file_multiple_delete_confirm'),
    'access arguments' => array('delete files'),
    'file' => 'file.pages.inc',
  );

  return $items;
}