You are here

protected function AjaxPageControllerBase::generateStateToken in Forena Reports 8

Generate a token for form

2 calls to AjaxPageControllerBase::generateStateToken()
AjaxPageControllerBase::getStateToken in src/Controller/AjaxPageControllerBase.php
Return the state token.
AjaxPageControllerBase::loadState in src/Controller/AjaxPageControllerBase.php
Loads the state from the token.

File

src/Controller/AjaxPageControllerBase.php, line 191

Class

AjaxPageControllerBase

Namespace

Drupal\forena\Controller

Code

protected function generateStateToken() {
  $this->token = static::TOKEN_PREFIX . '-' . bin2hex(openssl_random_pseudo_bytes(20));
}