function views_set_current_view
&views_set_current_view($view = NULL)
Set the current 'current view' that is being built/rendered so that it is easy for other modules or items in drupal_eval to identify
Return value
File
- core/modules/views/views.module, line 485
- Primarily Drupal hooks and global API functions to manipulate views.
Code
function &views_set_current_view($view = NULL) { static $cache = NULL; if (isset($view)) { $cache = $view; } return $cache; }
© 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!modules!views!views.module/function/views_set_current_view/8.1.x