Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
Javascript.php
Go to the documentation of this file.
1 <?php
7 
15 {
21  public function getScriptOptions()
22  {
23  $params = [
24  'url' => $this->getUrl(
25  'page_cache/block/render/',
26  [
27  '_current' => true,
28  '_secure' => $this->templateContext->getRequest()->isSecure()
29  ]
30  ),
31  'handles' => $this->_layout->getUpdate()->getHandles(),
32  'originalRequest' => [
33  'route' => $this->getRequest()->getRouteName(),
34  'controller' => $this->getRequest()->getControllerName(),
35  'action' => $this->getRequest()->getActionName(),
36  'uri' => $this->getRequest()->getRequestUri(),
37  ],
39  ];
40  return json_encode($params);
41  }
42 }
$params[\Magento\Store\Model\StoreManager::PARAM_RUN_CODE]
Definition: website.php:18