You are here

function _backup_migrate_process_destination_pulldown in Backup and Migrate 8.3

Same name and namespace in other branches
  1. 6.3 includes/destinations.inc \_backup_migrate_process_destination_pulldown()
  2. 7.3 includes/destinations.inc \_backup_migrate_process_destination_pulldown()

Return the destination pulldown with an option to save a second copy.

1 string reference to '_backup_migrate_process_destination_pulldown'
_backup_migrate_get_destination_pulldown in includes/destinations.inc
Get pulldown to select existing source options.

File

includes/destinations.inc, line 690

Code

function _backup_migrate_process_destination_pulldown($element) {
  $id = $element['destination_id']['#id'];
  $settings = array(
    'backup_migrate' => array(
      'destination_selectors' => array(
        $id => array(
          'destination_selector' => $id,
          'copy_destination_selector' => $element['copy_destination']['copy_destination_id']['#id'],
          'copy' => $element['copy']['#id'],
          'labels' => array(
            t('Local') => t('Save an offsite copy to'),
            t('Offsite') => t('Save a local copy to'),
          ),
        ),
      ),
    ),
  );
  drupal_add_js($settings, 'setting');
  return $element;
}