getSourceBasePath example

$driver = $connection_options['driver'];

    // Use the driver connection form to get the correct options out of the     // database settings. This supports all of the databases we test against.     $drivers = drupal_get_database_types();
    $form = $drivers[$driver]->getFormOptions($connection_options);
    $connection_options = array_intersect_key($connection_options$form + $form['advanced_options']);
    // Remove isolation_level since that option is not configurable in the UI.     unset($connection_options['isolation_level']);
    $edit = [
      $driver => $connection_options,
      'source_private_file_path' => $this->getSourceBasePath(),
      'version' => $version,
    ];
    if ($version == 6) {
      $edit['d6_source_base_path'] = $this->getSourceBasePath();
    }
    else {
      $edit['source_base_path'] = $this->getSourceBasePath();
      $edit['source_private_file_path'] = $this->getSourcePrivateBasePath();
    }
    if (count($drivers) !== 1) {
      $edit['driver'] = $driver;
    }
Home | Imprint | This part of the site doesn't use cookies.