Closed (works as designed)
Project:
Views (for Drupal 7)
Version:
6.x-2.6
Component:
block displays
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
29 Jun 2009 at 21:55 UTC
Updated:
30 Jun 2009 at 01:11 UTC
Hey there. I've got a view that takes a text field (a YouTube URL) and builds an embedded video widget for use in a block display, using it as a basis. The view rewrites the field_youtubevideo field to emit this properly.
However, the view emits no HTML whatsoever. I've done some fairly extensive experimentation to try to figure out the problem. It's not the field token and I don't think it has anything to do with rewriting, for a few reasons:
I would downgrade to Views 2.4, but doing so would jeopardize my work and I don't have an active play-around site to troubleshoot this on.
The view is below. As the SQL query clearly works fine, I have not included it.
Thanks,
Ed
$view = new view;
$view->name = 'slatestate_video_flagbox';
$view->description = 'This view displays the most recent Video Content node, without any title or description fixings.';
$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', 'Defaults', 'default');
$handler->override_option('fields', array(
'field_youtubevideo_value' => array(
'label' => '',
'alter' => array(
'alter_text' => 1,
'text' => '<object width="320" height="265"><param name="movie" value="[field_youtubevideo_value]&hl=en&fs=1&rel=0&color1=0x3a3a3a&color2=0x999999"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="[field_youtubevideo_value]&hl=en&fs=1&rel=0&color1=0x3a3a3a&color2=0x999999" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="320" height="265"></embed></object>',
'make_link' => 0,
'path' => '',
'link_class' => '',
'alt' => '',
'prefix' => '',
'suffix' => '',
'help' => '',
'trim' => 0,
'max_length' => '',
'word_boundary' => 1,
'ellipsis' => 1,
'strip_tags' => 0,
'html' => 0,
),
'link_to_node' => 0,
'label_type' => 'none',
'format' => 'default',
'multiple' => array(
'group' => TRUE,
'multiple_number' => '',
'multiple_from' => '',
'multiple_reversed' => FALSE,
),
'exclude' => 0,
'id' => 'field_youtubevideo_value',
'table' => 'node_data_field_youtubevideo',
'field' => 'field_youtubevideo_value',
'relationship' => 'none',
'override' => array(
'button' => 'Override',
),
),
));
$handler->override_option('sorts', array(
'created' => array(
'order' => 'DESC',
'granularity' => 'second',
'id' => 'created',
'table' => 'node',
'field' => 'created',
'relationship' => 'none',
),
));
$handler->override_option('filters', array(
'type' => array(
'operator' => 'in',
'value' => array(
'video' => 'video',
),
'group' => '0',
'exposed' => FALSE,
'expose' => array(
'operator' => FALSE,
'label' => '',
),
'id' => 'type',
'table' => 'node',
'field' => 'type',
'override' => array(
'button' => 'Override',
),
'relationship' => 'none',
),
));
$handler->override_option('access', array(
'type' => 'none',
));
$handler->override_option('cache', array(
'type' => 'none',
));
$handler->override_option('items_per_page', 1);
$handler->override_option('row_options', array(
'inline' => array(),
'separator' => '',
));
$handler = $view->new_display('block', 'Block', 'block_1');
$handler->override_option('block_description', '');
$handler->override_option('block_caching', -1);
Comments
Comment #1
merlinofchaos commentedobject tags are stripped out via filter_xss_admin() -- if you need object tags, you will need to add them at a lower level, i.e, the theming layer.