function file_entity_delete_form

cis7 file_entity.pages.inc file_entity_delete_form($form, &$form_state, $file)
cle7 file_entity.pages.inc file_entity_delete_form($form, &$form_state, $file)
elmsmedia7 file_entity.pages.inc file_entity_delete_form($form, &$form_state, $file)
icor7 file_entity.pages.inc file_entity_delete_form($form, &$form_state, $file)
meedjum_blog7 file_entity.pages.inc file_entity_delete_form($form, &$form_state, $file)
mooc7 file_entity.pages.inc file_entity_delete_form($form, &$form_state, $file)

Page callback: Form constructor for the file deletion confirmation form.

Path: file/%file/delete

Parameters

object $file: A file object from file_load().

See also

file_entity_menu()

2 string references to 'file_entity_delete_form'
file_entity_menu in sites/all/modules/ulmus/file_entity/file_entity.module
Implements hook_menu().
file_entity_page_delete in sites/all/modules/ulmus/file_entity/file_entity.pages.inc
Page callback for the file deletion confirmation form.

File

sites/all/modules/ulmus/file_entity/file_entity.pages.inc, line 817
Supports file operations including View, Edit, and Delete.

Code

function file_entity_delete_form($form, &$form_state, $file) {
  $form_state['file'] = $file;

  $form['fid'] = array(
    '#type' => 'value',
    '#value' => $file->fid,
  );

  $description = t('This action cannot be undone.');
  if ($references = file_usage_list($file)) {
    $description .= ' ' . t('This file is currently in use and may cause problems if deleted.');
  }

  return confirm_form($form, t('Are you sure you want to delete the file %title?', array(
    '%title' => entity_label('file', $file),
  )), 'file/' . $file->fid, $description, t('Delete'));
}
Error | ELMSLN API

Error

×

Error message

  • Warning: Cannot modify header information - headers already sent by (output started at /var/www/html/elmsln_community/api.elmsln.org/includes/common.inc:2791) in drupal_send_headers() (line 1499 of /var/www/html/elmsln_community/api.elmsln.org/includes/bootstrap.inc).
  • Error: Call to undefined function apc_delete() in DrupalAPCCache->clear() (line 289 of /var/www/html/elmsln_community/api.elmsln.org/sites/all/modules/apc/drupal_apc_cache.inc).
The website encountered an unexpected error. Please try again later.