Seting Views preprocess function for the specified view

Public

Seting Views preprocess function for the specified view

</> CopyGet raw version
php
  1. function MYMODULE_preprocess_views_view(&$vars) {
  2. $function_name = 'MYMODULE_preprocess_views_view__' . $vars['view']->name;
  3. if (function_exists($function_name)) {
  4. $function_name($vars);
  5. }
  6. }
  7.  
  8. function MYMODULE_preprocess_views_view__SYSTEM_VIEW_NAME(&$vars) {
  9. dpm($vars);
  10. // do stuff
  11. }