You are here

function backup_migrate_destination_browser_upload::load_file in Backup and Migrate 6.3

Same name and namespace in other branches
  1. 8.2 includes/destinations.browser.inc \backup_migrate_destination_browser_upload::load_file()
  2. 8.3 includes/destinations.browser.inc \backup_migrate_destination_browser_upload::load_file()
  3. 6.2 includes/destinations.browser.inc \backup_migrate_destination_browser_upload::load_file()
  4. 7.3 includes/destinations.browser.inc \backup_migrate_destination_browser_upload::load_file()
  5. 7.2 includes/destinations.browser.inc \backup_migrate_destination_browser_upload::load_file()

File load destination callback.

Overrides backup_migrate_destination::load_file

File

includes/destinations.browser.inc, line 41
Functions to handle the browser upload/download backup destination.

Class

backup_migrate_destination_browser_upload
A destination type for browser upload.

Code

function load_file($file_id) {
  backup_migrate_include('files');
  if ($file = file_save_upload('backup_migrate_restore_upload')) {
    $out = new backup_file(array(
      'filepath' => $file->filepath,
    ));
    backup_migrate_temp_files_add($file->filepath);
    return $out;
  }
  return NULL;
}