You are here

public function SettingsForm::buildForm in File (Field) Paths 8

Form constructor.

Parameters

array $form: An associative array containing the structure of the form.

\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.

Return value

array The form structure.

Overrides ConfigFormBase::buildForm

File

src/Form/SettingsForm.php, line 74

Class

SettingsForm
Administration settings form for File (Field) Paths.

Namespace

Drupal\filefield_paths\Form

Code

public function buildForm(array $form, FormStateInterface $form_state, Request $request = NULL) {
  $form['temp_location'] = [
    '#title' => $this
      ->t('Temporary file location'),
    '#type' => 'textfield',
    '#default_value' => $this
      ->config('filefield_paths.settings')
      ->get('temp_location'),
    '#description' => $this
      ->t('The location that unprocessed files will be uploaded prior to being processed by File (Field) Paths.<br />It is recommended that you use the temporary file system (temporary://) if your server configuration allows for that.'),
  ];
  return parent::buildForm($form, $form_state);
}