Mercurial > hg > rr-repo
diff sites/all/themes/omega/process/views/views-view-grid.process.inc @ 0:ff03f76ab3fe
initial version
author | danieleb <danielebarchiesi@me.com> |
---|---|
date | Wed, 21 Aug 2013 18:51:11 +0100 |
parents | |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/sites/all/themes/omega/process/views/views-view-grid.process.inc Wed Aug 21 18:51:11 2013 +0100 @@ -0,0 +1,20 @@ +<?php + +/** + * Implements hook_process_views_view_grid(). + * + * @see hook_preprocess_views_view_grid() + */ +function omega_process_views_view_grid(&$variables) { + $options = $variables['view']->style_plugin->options; + $columns = $options['columns']; + foreach ($variables['rows'] as $delta => $row) { + // Convert the previously set row attributes arrays into strings. + $variables['row_attributes'][$delta] = !empty($variables['row_attributes_array'][$delta]) ? drupal_attributes($variables['row_attributes_array'][$delta]) : ''; + + for ($column = 0; $column < $columns; $column++) { + // Convert the previously set column attributes arrays into strings. + $variables['column_attributes'][$delta][$column] = !empty($variables['column_attributes_array'][$delta][$column]) ? drupal_attributes($variables['column_attributes_array'][$delta][$column]) : ''; + } + } +}