You are here

public function TfaTestFallback::getForm in Two-factor Authentication (TFA) 7.2

Get TFA process form from plugin.

Parameters

array $form: The form array structure.

array $form_state: The current form state array.

Return value

array Form API array.

Overrides TfaValidationPluginInterface::getForm

File

tests/includes/tfa_test.fallback.inc, line 24
Tests for the TfaValidationPluginInterface.

Class

TfaTestFallback
Class TfaTestFallback.

Code

public function getForm(array $form, array &$form_state) {
  $form['recover'] = array(
    '#type' => 'textfield',
    '#title' => t('Enter recovery code'),
    '#required' => TRUE,
  );
  $form['login'] = array(
    '#type' => 'submit',
    '#value' => t('Submit'),
  );
  return $form;
}