$view = new view; $view->name = 'archive_blog'; $view->description = 'Archive for blogs'; $view->tag = ''; $view->view_php = ''; $view->base_table = 'node'; $view->is_cacheable = FALSE; $view->api_version = 2; $view->disabled = FALSE; /* Edit this to true to make a default view disabled initially */ $handler = $view->new_display('default', 'Archive', 'default'); $handler->override_option('fields', array( 'title' => array( 'id' => 'title', 'table' => 'node', 'field' => 'title', ), )); $handler->override_option('sorts', array( 'created' => array( 'order' => 'DESC', 'granularity' => 'second', 'id' => 'created', 'table' => 'node', 'field' => 'created', 'relationship' => 'none', ), )); $handler->override_option('arguments', array( 'uid' => array( 'default_action' => 'default', 'style_plugin' => 'default_summary', 'style_options' => array(), 'wildcard' => 'all', 'wildcard_substitution' => 'All', 'title' => '%1\'s archive', 'default_argument_type' => 'user', 'default_argument' => '', 'validate_type' => 'user', 'validate_fail' => 'not found', 'break_phrase' => 0, 'not' => 0, 'id' => 'uid', 'table' => 'users', 'field' => 'uid', 'validate_user_argument_type' => 'either', 'validate_user_roles' => array( '2' => 0, '3' => 0, '4' => 0, ), 'relationship' => 'none', 'default_options_div_prefix' => '', 'default_argument_user' => 1, 'default_argument_fixed' => '', 'default_argument_php' => '', 'validate_argument_node_type' => array( 'blog' => 0, 'book' => 0, 'page' => 0, 'showcase' => 0, 'story' => 0, ), 'validate_argument_node_access' => 0, 'validate_argument_nid_type' => 'nid', 'validate_argument_vocabulary' => array( '1' => 0, '4' => 0, '2' => 0, ), 'validate_argument_type' => 'tid', 'validate_argument_transform' => 0, 'validate_user_restrict_roles' => 0, 'validate_argument_php' => '', ), 'created_year_month' => array( 'default_action' => 'summary desc', 'style_plugin' => 'default_summary', 'style_options' => array( 'count' => 1, 'override' => 1, 'items_per_page' => '48', ), 'wildcard' => 'all', 'wildcard_substitution' => 'All', 'title' => '%1\'s archive %2', 'default_argument_type' => 'fixed', 'default_argument' => '', 'validate_type' => 'none', 'validate_fail' => 'summary desc', 'id' => 'created_year_month', 'table' => 'node', 'field' => 'created_year_month', 'relationship' => 'none', 'default_options_div_prefix' => '', 'default_argument_user' => 0, 'default_argument_fixed' => '', 'default_argument_php' => '', 'validate_argument_node_type' => array( 'blog' => 'blog', 'book' => 0, 'page' => 0, 'showcase' => 0, 'story' => 0, ), 'validate_argument_node_access' => 1, 'validate_argument_nid_type' => 'nid', 'validate_argument_vocabulary' => array( '1' => 0, '4' => 0, '2' => 0, ), 'validate_argument_type' => 'tid', 'validate_argument_php' => '', 'override' => array( 'button' => 'Override', ), 'user_argument_type' => '', 'restrict_user_roles' => 0, 'user_roles' => array(), ), )); $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( 'blog' => 'blog', 'story' => 'story', ), 'group' => '0', 'exposed' => FALSE, 'expose' => array( 'operator' => FALSE, 'label' => '', ), 'id' => 'type', 'table' => 'node', 'field' => 'type', 'relationship' => 'none', ), )); $handler->override_option('access', array( 'type' => 'none', 'role' => array(), 'perm' => '', )); $handler->override_option('cache', array( 'type' => 'none', )); $handler->override_option('title', 'Blog archive'); $handler->override_option('header_format', '1'); $handler->override_option('footer_format', '2'); $handler->override_option('empty_format', '2'); $handler->override_option('use_pager', TRUE); $handler->override_option('row_plugin', 'node'); $handler->override_option('row_options', array( 'teaser' => TRUE, 'links' => TRUE, )); $handler = $view->new_display('page', 'Page', 'page_1'); $handler->override_option('path', 'blog/%/archive'); $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, )); $handler = $view->new_display('block', 'Block', 'block_1'); $handler->override_option('arguments', array( 'uid' => array( 'default_action' => 'default', 'style_plugin' => 'default_summary', 'style_options' => array(), 'wildcard' => 'all', 'wildcard_substitution' => 'All', 'title' => '%1\'s archive', 'default_argument_type' => 'user', 'default_argument' => '', 'validate_type' => 'user', 'validate_fail' => 'not found', 'break_phrase' => 0, 'not' => 0, 'id' => 'uid', 'table' => 'users', 'field' => 'uid', 'validate_user_argument_type' => 'either', 'validate_user_roles' => array( '2' => 0, '3' => 0, '4' => 0, ), 'relationship' => 'none', 'default_options_div_prefix' => '', 'default_argument_user' => 1, 'default_argument_fixed' => '', 'default_argument_php' => '', 'validate_argument_node_type' => array( 'blog' => 0, 'book' => 0, 'page' => 0, 'showcase' => 0, 'story' => 0, ), 'validate_argument_node_access' => 0, 'validate_argument_nid_type' => 'nid', 'validate_argument_vocabulary' => array( '1' => 0, '4' => 0, '2' => 0, ), 'validate_argument_type' => 'tid', 'validate_argument_transform' => 0, 'validate_user_restrict_roles' => 0, 'validate_argument_php' => '', ), 'created_year_month' => array( 'default_action' => 'summary desc', 'style_plugin' => 'default_summary', 'style_options' => array( 'count' => 1, 'override' => 1, 'items_per_page' => '12', ), 'wildcard' => 'all', 'wildcard_substitution' => 'All', 'title' => '%1\'s archive %2', 'default_argument_type' => 'fixed', 'default_argument' => '', 'validate_type' => 'none', 'validate_fail' => 'summary desc', 'id' => 'created_year_month', 'table' => 'node', 'field' => 'created_year_month', 'relationship' => 'none', 'default_options_div_prefix' => '', 'default_argument_user' => 0, 'default_argument_fixed' => '', 'default_argument_php' => '', 'validate_argument_node_type' => array( 'blog' => 'blog', 'book' => 0, 'page' => 0, 'showcase' => 0, 'story' => 0, ), 'validate_argument_node_access' => 1, 'validate_argument_nid_type' => 'nid', 'validate_argument_vocabulary' => array( '1' => 0, '4' => 0, '2' => 0, ), 'validate_argument_type' => 'tid', 'validate_argument_php' => '', 'override' => array( 'button' => 'Override', ), 'user_argument_type' => '', 'restrict_user_roles' => 0, 'user_roles' => array(), ), )); $handler->override_option('items_per_page', 12); $handler->override_option('use_pager', '0'); $handler->override_option('use_more', 1); $handler->override_option('style_plugin', 'list'); $handler->override_option('style_options', array( 'type' => 'ul', )); $handler->override_option('row_plugin', 'fields'); $handler->override_option('block_description', ''); $handler->override_option('block_caching', '4');