W3cubDocs

/Drupal 8

protected property FormState::$requestMethod

The HTTP method used by the request building or processing this form.

May be any valid HTTP method. Defaults to 'GET', because even though $method is 'POST' for most forms, the form's initial build is usually performed as part of a GET request.

This property is uncacheable.

Type: string

File

core/lib/Drupal/Core/Form/FormState.php, line 174

Class

FormState
Stores information about the state of a form.

Namespace

Drupal\Core\Form

Code

protected $requestMethod = 'GET';

© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!lib!Drupal!Core!Form!FormState.php/property/FormState::requestMethod/8.1.x