views_pre_render_views_form_views_form

views_pre_render_views_form_views_form($element) Replaces views substitution placeholders. Parameters array $element: An associative array containing the properties of the element. Properties used: #substitutions, #children. Return value array The $element with prepared variables ready for #theme 'form' in views_form_views_form. File core/modules/views/views.module, line 606 Primarily Drupal hooks and global API functions to manipulate views. Code function views_pre_render_views_form_views_

views_preprocess_node

views_preprocess_node(&$variables) A theme preprocess function to automatically allow view-based node templates if called from a view. The 'modules/node.views.inc' file is a better place for this, but we haven't got a chance to load that file before Drupal builds the node portion of the theme registry. File core/modules/views/views.module, line 232 Primarily Drupal hooks and global API functions to manipulate views. Code function views_preprocess_node(&$variables) { // The 'view' at

views_preprocess_comment

views_preprocess_comment(&$variables) A theme preprocess function to automatically allow view-based node templates if called from a view. File core/modules/views/views.module, line 265 Primarily Drupal hooks and global API functions to manipulate views. Code function views_preprocess_comment(&$variables) { // The view data is added to the comment in // \Drupal\views\Plugin\views\row\EntityRow::preRender(). if (!empty($variables['comment']->view) && $variables['comment

views_post_update_cleanup_duplicate_views_data

views_post_update_cleanup_duplicate_views_data() Update some views fields that were previously duplicated. File core/modules/views/views.post_update.php, line 50 Post update functions for Views. Code function views_post_update_cleanup_duplicate_views_data() { $config_factory = \Drupal::configFactory(); $ids = []; $message = NULL; $data_tables = []; $base_tables = []; $revision_tables = []; $entities_by_table = []; $duplicate_fields = []; $handler_types = Views::getHandlerTyp

views_local_tasks_alter

views_local_tasks_alter(&$local_tasks) Implements hook_local_tasks_alter(). File core/modules/views/views.module, line 811 Primarily Drupal hooks and global API functions to manipulate views. Code function views_local_tasks_alter(&$local_tasks) { $container = \Drupal::getContainer(); $local_task = ViewsLocalTask::create($container, 'views_view'); $local_task->alterLocalTasks($local_tasks); }

views_invalidate_cache

views_invalidate_cache() Invalidate the views cache, forcing a rebuild on the next grab of table data. File core/modules/views/views.module, line 461 Primarily Drupal hooks and global API functions to manipulate views. Code function views_invalidate_cache() { // Set the menu as needed to be rebuilt. \Drupal::service('router.builder')->setRebuildNeeded(); $module_handler = \Drupal::moduleHandler(); // Reset the RouteSubscriber from views. \Drupal::getContainer()->get('views.r

views_hook_info

views_hook_info() Implements hook_hook_info(). File core/modules/views/views.module, line 510 Primarily Drupal hooks and global API functions to manipulate views. Code function views_hook_info() { $hooks = array(); $hooks += array_fill_keys(array( 'views_data', 'views_data_alter', 'views_analyze', 'views_invalidate_cache', ), array('group' => 'views')); // Register a views_plugins alter hook for all plugin types. foreach (ViewExecutable::getPluginTypes() as $typ

views_help

views_help($route_name, RouteMatchInterface $route_match) Implements hook_help(). File core/modules/views/views.module, line 25 Primarily Drupal hooks and global API functions to manipulate views. Code function views_help($route_name, RouteMatchInterface $route_match) { switch ($route_name) { case 'help.page.views': $output = ''; $output .= '<h3>' . t('About') . '</h3>'; $output .= '<p>' . t('The Views module provides a back end to fetch information f

views_get_view_result

views_get_view_result($name, $display_id = NULL) Get the result of a view. Parameters string $name: The name of the view to retrieve the data from. string $display_id: The display id. On the edit page for the view in question, you'll find a list of displays at the left side of the control area. "Master" will be at the top of that list. Hover your cursor over the name of the display you want to use. A URL will appear in the status bar of your browser. This is usually at the bottom of the window

views_get_current_view

&views_get_current_view() Find out what, if any, current view is currently in use. Note that this returns a reference, so be careful! You can unintentionally modify the $view object. Return value \Drupal\views\ViewExecutable The current view object. File core/modules/views/views.module, line 503 Primarily Drupal hooks and global API functions to manipulate views. Code function &views_get_current_view() { return views_set_current_view(); }