function AjaxPageState::parseAjaxPageState

Same name and namespace in other branches
  1. 10 core/lib/Drupal/Core/StackMiddleware/AjaxPageState.php \Drupal\Core\StackMiddleware\AjaxPageState::parseAjaxPageState()

Parse the ajax_page_state variable in the request.

Decompresses the libraries array key.

Parameters

array $ajax_page_state: An array of query parameters, where the libraries parameter is compressed.

Return value

array

1 call to AjaxPageState::parseAjaxPageState()
AjaxPageState::handle in core/lib/Drupal/Core/StackMiddleware/AjaxPageState.php

File

core/lib/Drupal/Core/StackMiddleware/AjaxPageState.php, line 49

Class

AjaxPageState
Expands the compressed ajax_page_state query parameter into an array.

Namespace

Drupal\Core\StackMiddleware

Code

private function parseAjaxPageState(array $ajax_page_state) : array {
    $ajax_page_state['libraries'] = UrlHelper::uncompressQueryParameter($ajax_page_state['libraries']);
    return $ajax_page_state;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.