You are here

public function ToolbarController::reloadPage in Admin Toolbar 8

Same name and namespace in other branches
  1. 8.2 admin_toolbar_tools/src/Controller/ToolbarController.php \Drupal\admin_toolbar_tools\Controller\ToolbarController::reloadPage()
  2. 3.x admin_toolbar_tools/src/Controller/ToolbarController.php \Drupal\admin_toolbar_tools\Controller\ToolbarController::reloadPage()

Reload the previous page.

9 calls to ToolbarController::reloadPage()
ToolbarController::cacheRender in admin_toolbar_tools/src/Controller/ToolbarController.php
Clear the rendered cache.
ToolbarController::flushAll in admin_toolbar_tools/src/Controller/ToolbarController.php
Flushes all caches.
ToolbarController::flushJsCss in admin_toolbar_tools/src/Controller/ToolbarController.php
Flushes css and javascript caches.
ToolbarController::flushMenu in admin_toolbar_tools/src/Controller/ToolbarController.php
Clears all cached menu data.
ToolbarController::flushPlugins in admin_toolbar_tools/src/Controller/ToolbarController.php
Flushes plugins caches.

... See full list

File

admin_toolbar_tools/src/Controller/ToolbarController.php, line 175

Class

ToolbarController
Class ToolbarController.

Namespace

Drupal\admin_toolbar_tools\Controller

Code

public function reloadPage() {
  $request = $this->requestStack
    ->getCurrentRequest();
  if ($request->server
    ->get('HTTP_REFERER')) {
    return $request->server
      ->get('HTTP_REFERER');
  }
  else {
    return '/';
  }
}