Closed (fixed)
Project:
Views (for Drupal 7)
Version:
5.x-1.6-beta5
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
14 May 2007 at 15:44 UTC
Updated:
1 Jun 2007 at 14:31 UTC
I'm trying to create a fairly simple block that lists titles for nodes with a a particular taxonomy term. For some reason I don't get any content when I use the "List" view, though the view works fine when I use "Table". Here is the export output of both versions:
The list view doesn't display any content, but it does display a series of tags that look meant to hold content:
$view = new stdClass();
$view->name = 'viz_arts_list';
$view->description = 'Recent content from the Visual Arts Collective';
$view->access = array (
);
$view->view_args_php = '';
$view->block = TRUE;
$view->block_title = 'Current Exhibitions as List';
$view->block_header = '';
$view->block_header_format = '1';
$view->block_footer = '';
$view->block_footer_format = '1';
$view->block_empty = '(Sorry, there isn\'t any content for this block right now.)';
$view->block_empty_format = '1';
$view->block_type = 'list';
$view->nodes_per_block = '5';
$view->block_more = FALSE;
$view->block_use_page_header = FALSE;
$view->block_use_page_footer = FALSE;
$view->block_use_page_empty = FALSE;
$view->sort = array (
);
$view->argument = array (
);
$view->field = array (
array (
'tablename' => 'node',
'field' => 'type',
'label' => '',
),
array (
'tablename' => 'node',
'field' => 'title',
'label' => '',
'handler' => 'views_handler_field_nodelink',
'options' => 'link',
),
);
$view->filter = array (
array (
'tablename' => 'node',
'field' => 'status',
'operator' => '=',
'options' => '',
'value' => '1',
),
array (
'tablename' => 'term_node_1',
'field' => 'tid',
'operator' => 'OR',
'options' => '',
'value' => array (
0 => '1',
),
),
);
$view->exposed_filter = array (
);
$view->requires = array(node, term_node_1);
$views[$view->name] = $view;
The table view works fine, but produces a table ...
$view = new stdClass();
$view->name = 'viz_arts_alt';
$view->description = 'Recent content from the Visual Arts Collective';
$view->access = array (
);
$view->view_args_php = '';
$view->block = TRUE;
$view->block_title = 'Current Exhibitions';
$view->block_header = '';
$view->block_header_format = '1';
$view->block_footer = '';
$view->block_footer_format = '1';
$view->block_empty = '(Sorry, there isn\'t any content for this block right now.)';
$view->block_empty_format = '1';
$view->block_type = 'table';
$view->nodes_per_block = '5';
$view->block_more = FALSE;
$view->block_use_page_header = FALSE;
$view->block_use_page_footer = FALSE;
$view->block_use_page_empty = FALSE;
$view->sort = array (
);
$view->argument = array (
);
$view->field = array (
array (
'tablename' => 'node',
'field' => 'type',
'label' => '',
),
array (
'tablename' => 'node',
'field' => 'title',
'label' => '',
'handler' => 'views_handler_field_nodelink',
'options' => 'link',
),
);
$view->filter = array (
array (
'tablename' => 'node',
'field' => 'status',
'operator' => '=',
'options' => '',
'value' => '1',
),
array (
'tablename' => 'term_node_1',
'field' => 'tid',
'operator' => 'OR',
'options' => '',
'value' => array (
0 => '1',
),
),
);
$view->exposed_filter = array (
);
$view->requires = array(node, term_node_1);
$views[$view->name] = $view;
Comments
Comment #1
amanda commentedHere is the output in html of each block:
The Table ...
Vs. the output for the list view:
Comment #2
amanda commentedupgrading to 5.x-1.6-beta5 seems to have resolved this.
Comment #3
amanda commentedComment #4
(not verified) commented