You are here

function backup_migrate_destination_s3::edit_form in Backup and Migrate 6.3

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

Get the form for the settings for this filter.

Overrides backup_migrate_destination_remote::edit_form

File

includes/destinations.s3.inc, line 80
Functions to handle the s3 backup destination.

Class

backup_migrate_destination_s3
A destination for sending database backups to an s3 server.

Code

function edit_form() {

  // Check for the library.
  $this
    ->s3_object();
  $form = parent::edit_form();
  $form['scheme']['#type'] = 'value';
  $form['scheme']['#value'] = 'https';
  $form['host']['#type'] = 'value';
  $form['host']['#value'] = 's3.amazonaws.com';
  $form['path']['#title'] = 'S3 Bucket';
  $form['path']['#default_value'] = $this
    ->get_bucket();
  $form['path']['#description'] = 'This bucket must already exist. It will not be created for you.';
  $form['user']['#title'] = 'Access Key ID';
  $form['pass']['#title'] = 'Secret Access Key';
  $form['subdir'] = array(
    '#type' => 'textfield',
    '#title' => t('Subdirectory'),
    '#default_value' => $this
      ->get_subdir(),
    '#weight' => 25,
  );
  $form['settings']['#weight'] = 50;
  return $form;
}