Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $view = new view;
- $view->name = 'image_gallery';
- $view->description = 'The default gallery of image nodes from Image gallery module.';
- $view->tag = 'image_gallery';
- $view->base_table = 'node';
- $view->core = 0;
- $view->api_version = '2';
- $view->disabled = FALSE; /* Edit this to true to make a default view disabled initially */
- $handler = $view->new_display('default', 'Defaults', 'default');
- $handler->override_option('fields', array(
- 'image_image' => array(
- 'label' => '',
- 'alter' => array(
- 'alter_text' => 0,
- 'text' => '',
- 'make_link' => 0,
- 'path' => '',
- 'alt' => '',
- 'prefix' => '',
- 'suffix' => '',
- 'help' => '',
- 'trim' => 0,
- 'max_length' => '',
- 'word_boundary' => 1,
- 'ellipsis' => 1,
- 'html' => 0,
- ),
- 'link_to_node' => 1,
- 'image_derivative' => 'thumbnail',
- 'exclude' => 0,
- 'id' => 'image_image',
- 'table' => 'node',
- 'field' => 'image_image',
- 'relationship' => 'none',
- ),
- 'title' => array(
- 'label' => '',
- 'alter' => array(
- 'alter_text' => 0,
- 'text' => '',
- 'make_link' => 0,
- 'path' => '',
- 'alt' => '',
- 'prefix' => '',
- 'suffix' => '',
- 'help' => '',
- 'trim' => 0,
- 'max_length' => '',
- 'word_boundary' => 1,
- 'ellipsis' => 1,
- 'html' => 0,
- ),
- 'link_to_node' => 1,
- 'exclude' => 0,
- 'id' => 'title',
- 'table' => 'node',
- 'field' => 'title',
- 'relationship' => 'none',
- ),
- ));
- $handler->override_option('sorts', array(
- 'title' => array(
- 'id' => 'title',
- 'table' => 'node',
- 'field' => 'title',
- ),
- 'changed' => array(
- 'order' => 'DESC',
- 'granularity' => 'second',
- 'id' => 'changed',
- 'table' => 'node',
- 'field' => 'changed',
- 'relationship' => 'none',
- ),
- ));
- $handler->override_option('filters', array(
- 'status' => array(
- 'operator' => '=',
- 'value' => '1',
- 'group' => '0',
- 'exposed' => FALSE,
- 'expose' => array(
- 'operator' => FALSE,
- 'label' => '',
- ),
- 'id' => 'status',
- 'table' => 'node',
- 'field' => 'status',
- 'relationship' => 'none',
- ),
- 'type' => array(
- 'operator' => 'in',
- 'value' => array(
- 'image' => 'image',
- ),
- 'group' => '0',
- 'exposed' => FALSE,
- 'expose' => array(
- 'operator' => FALSE,
- 'label' => '',
- ),
- 'id' => 'type',
- 'table' => 'node',
- 'field' => 'type',
- 'relationship' => 'none',
- ),
- ));
- $handler->override_option('access', array(
- 'type' => 'none',
- ));
- $handler->override_option('cache', array(
- 'type' => 'none',
- ));
- $handler->override_option('title', 'Image galleries');
- $handler->override_option('empty', 'There are no images in this gallery.');
- $handler->override_option('empty_format', '1');
- $handler->override_option('items_per_page', 12);
- $handler->override_option('use_pager', '1');
- $handler->override_option('style_plugin', 'image_gallery');
- $handler->override_option('style_options', array(
- 'grouping' => '',
- 'type' => 'ul',
- ));
- $handler = $view->new_display('image_gallery', 'Gallery page', 'image_gallery_1');
- $handler->override_option('path', 'image');
- $handler->override_option('menu', array(
- 'type' => 'none',
- 'title' => '',
- 'description' => '',
- 'weight' => 0,
- 'name' => 'navigation',
- ));
- $handler->override_option('tab_options', array(
- 'type' => 'none',
- 'title' => '',
- 'description' => '',
- 'weight' => 0,
- 'name' => 'navigation',
- ));
- $handler = $view->new_display('block', 'Block', 'block_1');
- $handler->override_option('filters', array(
- 'status' => array(
- 'operator' => '=',
- 'value' => '1',
- 'group' => '0',
- 'exposed' => FALSE,
- 'expose' => array(
- 'operator' => FALSE,
- 'label' => '',
- ),
- 'id' => 'status',
- 'table' => 'node',
- 'field' => 'status',
- 'relationship' => 'none',
- ),
- 'type' => array(
- 'operator' => 'in',
- 'value' => array(
- 'image' => 'image',
- ),
- 'group' => '0',
- 'exposed' => FALSE,
- 'expose' => array(
- 'operator' => FALSE,
- 'label' => '',
- ),
- 'id' => 'type',
- 'table' => 'node',
- 'field' => 'type',
- 'relationship' => 'none',
- ),
- 'name' => array(
- 'operator' => '=',
- 'value' => 'EventGallery',
- 'group' => '0',
- 'exposed' => FALSE,
- 'expose' => array(
- 'operator' => FALSE,
- 'label' => '',
- 'optional' => FALSE,
- ),
- 'case' => 1,
- 'id' => 'name',
- 'table' => 'term_data',
- 'field' => 'name',
- 'override' => array(
- 'button' => 'Use default',
- ),
- 'relationship' => 'none',
- ),
- ));
- $handler->override_option('title', 'Image Gallery');
- $handler->override_option('block_description', '');
- $handler->override_option('block_caching', -1);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement