function views_set_current_view

cis7 views.module &views_set_current_view($view = NULL)
cle7 views.module &views_set_current_view($view = NULL)
elmsmedia7 views.module &views_set_current_view($view = NULL)
icor7 views.module &views_set_current_view($view = NULL)
meedjum_blog7 views.module &views_set_current_view($view = NULL)
mooc7 views.module &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


3 calls to views_set_current_view()
view::post_execute in sites/all/modules/ulmus/views/includes/
Unset the current view, mostly.
view::pre_execute in sites/all/modules/ulmus/views/includes/
Run attachments and let the display do what it needs to do prior to running.
views_get_current_view in sites/all/modules/ulmus/views/views.module
Find out what, if any, current view is currently in use. Please note that this returns a reference, so be careful! You can unintentionally modify the $view object.


sites/all/modules/ulmus/views/views.module, line 1042
Primarily Drupal hooks and global API functions to manipulate views.


function &views_set_current_view($view = NULL) {
  static $cache = NULL;
  if (isset($view)) {
    $cache = $view;

  return $cache;



Error message

  • Warning: Cannot modify header information - headers already sent by (output started at /var/www/html/elmsln_community/ in drupal_send_headers() (line 1499 of /var/www/html/elmsln_community/
  • Error: Call to undefined function apc_delete() in DrupalAPCCache->clear() (line 289 of /var/www/html/elmsln_community/
The website encountered an unexpected error. Please try again later.