I'm trying to add the RSS feed icon to some of the displays for my view (view export included at the bottom). I have set up the "feed display" in my view (no arguments), and previewing the feed in the UI gives me the result I need.

I then attached the feed display to my other displays (some block displays, some page displays, and the "defaults"). The feed icon shows up when previewing the "defaults" display, but is missing on all the other displays to which the feed display is attached.

The "defaults" display and the other displays are using the same template file, which was copied from the views/theme directory, and contains the code to display the icon:

  <?php if ($feed_icon): ?>
    <div class="feed-icon">
      <?php print $feed_icon; ?>
    </div>
  <?php endif; ?>

When I try and dump the $feed_icon variable in my template, the result is an empty string. (except in the "Defaults"-display). No error or warning messages are displayed when previewing the different displays.

For the life of me I can't figure out why it works on the defaults display and not on any of the other displays.

Does anyone see what I'm doing wrong?

View export:

$view = new view;
$view->name = 'Stories';
$view->description = 'Stories';
$view->tag = 'x';
$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(
  'title' => array(
    'label' => '',
    'link_to_node' => 1,
    'exclude' => 0,
    'id' => 'title',
    'table' => 'node',
    'field' => 'title',
    'relationship' => 'none',
  ),
  'view_node' => array(
    'label' => '',
    'text' => 'Read more',
    'exclude' => 1,
    'id' => 'view_node',
    'table' => 'node',
    'field' => 'view_node',
    'relationship' => 'none',
  ),
  'field_breaking_value' => array(
    'label' => '',
    'link_to_node' => 0,
    'label_type' => 'none',
    'format' => 'default',
    'multiple' => array(
      'group' => TRUE,
      'multiple_number' => '',
      'multiple_from' => '',
      'multiple_reversed' => FALSE,
    ),
    'exclude' => 1,
    'id' => 'field_breaking_value',
    'table' => 'node_data_field_breaking',
    'field' => 'field_breaking_value',
    'relationship' => 'none',
  ),
  'field_publication_date_value' => array(
    'label' => '',
    'link_to_node' => 0,
    'label_type' => 'none',
    'format' => 'default',
    'multiple' => array(
      'group' => TRUE,
      'multiple_number' => '',
      'multiple_from' => '',
      'multiple_reversed' => FALSE,
    ),
    'exclude' => 0,
    'id' => 'field_publication_date_value',
    'table' => 'node_data_field_publication_date',
    'field' => 'field_publication_date_value',
    'relationship' => 'none',
  ),
  'field_source_value' => array(
    'label' => '',
    'link_to_node' => 0,
    'label_type' => 'none',
    'format' => 'default',
    'multiple' => array(
      'group' => TRUE,
      'multiple_number' => '',
      'multiple_from' => '',
      'multiple_reversed' => FALSE,
    ),
    'exclude' => 0,
    'id' => 'field_source_value',
    'table' => 'node_data_field_source',
    'field' => 'field_source_value',
    'relationship' => 'none',
    'override' => array(
      'button' => 'Override',
    ),
  ),
  'field_summary_value' => array(
    'id' => 'field_summary_value',
    'table' => 'node_data_field_summary',
    'field' => 'field_summary_value',
  ),
));
$handler->override_option('sorts', array(
  'field_publication_date_value' => array(
    'order' => 'DESC',
    'delta' => -1,
    'id' => 'field_publication_date_value',
    'table' => 'node_data_field_publication_date',
    'field' => 'field_publication_date_value',
    'relationship' => 'none',
  ),
));
$handler->override_option('arguments', array(
  'name' => array(
    'id' => 'name',
    'table' => 'term_data',
    'field' => 'name',
  ),
  'date_argument' => array(
    'id' => 'date_argument',
    'table' => 'node',
    'field' => 'date_argument',
  ),
));
$handler->override_option('filters', array(
  'type' => array(
    'operator' => 'in',
    'value' => array(
      'news' => 'news',
    ),
    'group' => '0',
    'exposed' => FALSE,
    'expose' => array(
      'operator' => FALSE,
      'label' => '',
    ),
    'id' => 'type',
    'table' => 'node',
    'field' => 'type',
    'relationship' => 'none',
  ),
  'vid' => array(
    'operator' => 'in',
    'value' => array(
      '3' => '3',
    ),
    'group' => '0',
    'exposed' => FALSE,
    'expose' => array(
      'operator' => FALSE,
      'label' => '',
    ),
    'id' => 'vid',
    'table' => 'term_data',
    'field' => 'vid',
    'relationship' => 'none',
  ),
));
$handler->override_option('access', array(
  'type' => 'none',
));
$handler->override_option('title', 'Stories');
$handler->override_option('empty', 'There are no stories.');
$handler->override_option('empty_format', '2');
$handler->override_option('items_per_page', 5);
$handler->override_option('use_pager', '1');
$handler->override_option('pager_element', 10);
$handler->override_option('style_plugin', 'list');
$handler->override_option('style_options', array(
  'grouping' => '',
  'type' => 'ul',
));
$handler = $view->new_display('page', 'News Page', 'page_1');
$handler->override_option('fields', array(
  'title' => array(
    'label' => '',
    'link_to_node' => 1,
    'exclude' => 0,
    'id' => 'title',
    'table' => 'node',
    'field' => 'title',
    'relationship' => 'none',
  ),
  'view_node' => array(
    'label' => '',
    'text' => 'Read more',
    'exclude' => 1,
    'id' => 'view_node',
    'table' => 'node',
    'field' => 'view_node',
    'relationship' => 'none',
  ),
  'field_breaking_value' => array(
    'label' => '',
    'link_to_node' => 0,
    'label_type' => 'none',
    'format' => 'default',
    'multiple' => array(
      'group' => TRUE,
      'multiple_number' => '',
      'multiple_from' => '',
      'multiple_reversed' => FALSE,
    ),
    'exclude' => 1,
    'id' => 'field_breaking_value',
    'table' => 'node_data_field_breaking',
    'field' => 'field_breaking_value',
    'relationship' => 'none',
  ),
  'field_publication_date_value' => array(
    'label' => '',
    'link_to_node' => 0,
    'label_type' => 'none',
    'format' => 'default',
    'multiple' => array(
      'group' => TRUE,
      'multiple_number' => '',
      'multiple_from' => '',
      'multiple_reversed' => FALSE,
    ),
    'exclude' => 0,
    'id' => 'field_publication_date_value',
    'table' => 'node_data_field_publication_date',
    'field' => 'field_publication_date_value',
    'relationship' => 'none',
    'override' => array(
      'button' => 'Use default',
    ),
  ),
  'field_source_value' => array(
    'label' => '',
    'link_to_node' => 0,
    'label_type' => 'none',
    'format' => 'default',
    'multiple' => array(
      'group' => TRUE,
      'multiple_number' => '',
      'multiple_from' => '',
      'multiple_reversed' => FALSE,
    ),
    'exclude' => 0,
    'id' => 'field_source_value',
    'table' => 'node_data_field_source',
    'field' => 'field_source_value',
    'relationship' => 'none',
    'override' => array(
      'button' => 'Use default',
    ),
  ),
  'field_summary_value' => array(
    'label' => 'Summary',
    'link_to_node' => 0,
    'label_type' => 'widget',
    'format' => 'default',
    'multiple' => array(
      'group' => TRUE,
      'multiple_number' => '',
      'multiple_from' => '',
      'multiple_reversed' => FALSE,
    ),
    'exclude' => 0,
    'id' => 'field_summary_value',
    'table' => 'node_data_field_summary',
    'field' => 'field_summary_value',
    'override' => array(
      'button' => 'Use default',
    ),
    'relationship' => 'none',
  ),
));
$handler->override_option('arguments', array(
  'name' => array(
    'default_action' => 'ignore',
    'style_plugin' => 'default_summary',
    'style_options' => array(),
    'wildcard' => 'all',
    'wildcard_substitution' => 'All',
    'title' => '%1',
    'default_argument_type' => 'fixed',
    'default_argument' => '',
    'validate_type' => 'php',
    'validate_fail' => 'not found',
    'glossary' => 0,
    'limit' => '0',
    'case' => 'none',
    'path_case' => 'lower',
    'transform_dash' => 0,
    'add_table' => 0,
    'require_value' => 0,
    'id' => 'name',
    'table' => 'term_data',
    'field' => 'name',
    'override' => array(
      'button' => 'Use default',
    ),
    'relationship' => 'none',
    'default_options_div_prefix' => '',
    'default_argument_user' => 0,
    'default_argument_fixed' => '',
    'default_argument_php' => '',
    'validate_argument_node_type' => array(
      'news' => 0,
      'page' => 0,
    ),
    'validate_argument_node_access' => 0,
    'validate_argument_nid_type' => 'nid',
    'validate_argument_vocabulary' => array(
      '1' => 0,
      '3' => 0,
    ),
    'validate_argument_type' => 'tid',
    'validate_argument_php' => '$spaced = str_replace(\'-\', \' \', $argument);
            
            if (taxonomy_get_term_by_name($argument)) { 
              // is there such a term?
              $terms = taxonomy_get_term_by_name($argument);
              $handler->argument = $terms[0]->name;  
              return TRUE;
            }
            else if (taxonomy_get_term_by_name($spaced)) {
            $terms = taxonomy_get_term_by_name($spaced);
            $handler->argument = $terms[0]->name;  
              return TRUE;
            }
            else
            {
              return FALSE;
            }',
  ),
));
$handler->override_option('filters', array(
  'type' => array(
    'operator' => 'in',
    'value' => array(
      'news' => 'news',
    ),
    'group' => '0',
    'exposed' => FALSE,
    'expose' => array(
      'operator' => FALSE,
      'label' => '',
    ),
    'id' => 'type',
    'table' => 'node',
    'field' => 'type',
    'relationship' => 'none',
  ),
  'vid' => array(
    'operator' => 'in',
    'value' => array(
      '3' => '3',
    ),
    'group' => '0',
    'exposed' => FALSE,
    'expose' => array(
      'operator' => FALSE,
      'label' => '',
    ),
    'id' => 'vid',
    'table' => 'term_data',
    'field' => 'vid',
    'relationship' => 'none',
  ),
  'date_filter' => array(
    'operator' => '>=',
    'value' => array(
      'value' => NULL,
      'min' => NULL,
      'max' => NULL,
      'default_date' => 'now -60 day',
      'default_to_date' => '',
    ),
    'group' => '0',
    'exposed' => FALSE,
    'expose' => array(
      'operator' => FALSE,
      'label' => '',
    ),
    'date_fields' => array(
      'node_data_field_publication_date.field_publication_date_value' => 'node_data_field_publication_date.field_publication_date_value',
    ),
    'granularity' => 'day',
    'form_type' => 'date_select',
    'default_date' => 'now -60 day',
    'default_to_date' => '',
    'id' => 'date_filter',
    'table' => 'node',
    'field' => 'date_filter',
    'override' => array(
      'button' => 'Use default',
    ),
    'relationship' => 'none',
  ),
));
$handler->override_option('title', 'News & Resources');
$handler->override_option('path', 'news/%');
$handler->override_option('menu', array(
  'type' => 'none',
  'title' => '',
  'weight' => 0,
  'name' => 'navigation',
));
$handler->override_option('tab_options', array(
  'type' => 'none',
  'title' => '',
  'weight' => 0,
));
$handler = $view->new_display('page', 'News Page Archive Month', 'page_2');
$handler->override_option('fields', array(
  'title' => array(
    'label' => '',
    'link_to_node' => 1,
    'exclude' => 0,
    'id' => 'title',
    'table' => 'node',
    'field' => 'title',
    'relationship' => 'none',
  ),
  'view_node' => array(
    'label' => '',
    'text' => 'Read more',
    'exclude' => 1,
    'id' => 'view_node',
    'table' => 'node',
    'field' => 'view_node',
    'relationship' => 'none',
  ),
  'field_breaking_value' => array(
    'label' => '',
    'link_to_node' => 0,
    'label_type' => 'none',
    'format' => 'default',
    'multiple' => array(
      'group' => TRUE,
      'multiple_number' => '',
      'multiple_from' => '',
      'multiple_reversed' => FALSE,
    ),
    'exclude' => 1,
    'id' => 'field_breaking_value',
    'table' => 'node_data_field_breaking',
    'field' => 'field_breaking_value',
    'relationship' => 'none',
  ),
  'field_publication_date_value' => array(
    'label' => '',
    'link_to_node' => 0,
    'label_type' => 'none',
    'format' => 'default',
    'multiple' => array(
      'group' => TRUE,
      'multiple_number' => '',
      'multiple_from' => '',
      'multiple_reversed' => FALSE,
    ),
    'exclude' => 0,
    'id' => 'field_publication_date_value',
    'table' => 'node_data_field_publication_date',
    'field' => 'field_publication_date_value',
    'relationship' => 'none',
    'override' => array(
      'button' => 'Use default',
    ),
  ),
  'field_source_value' => array(
    'label' => '',
    'link_to_node' => 0,
    'label_type' => 'none',
    'format' => 'default',
    'multiple' => array(
      'group' => TRUE,
      'multiple_number' => '',
      'multiple_from' => '',
      'multiple_reversed' => FALSE,
    ),
    'exclude' => 0,
    'id' => 'field_source_value',
    'table' => 'node_data_field_source',
    'field' => 'field_source_value',
    'relationship' => 'none',
    'override' => array(
      'button' => 'Use default',
    ),
  ),
  'field_summary_value' => array(
    'label' => '',
    'link_to_node' => 0,
    'label_type' => 'none',
    'format' => 'default',
    'multiple' => array(
      'group' => TRUE,
      'multiple_number' => '',
      'multiple_from' => '',
      'multiple_reversed' => FALSE,
    ),
    'exclude' => 0,
    'id' => 'field_summary_value',
    'table' => 'node_data_field_summary',
    'field' => 'field_summary_value',
    'override' => array(
      'button' => 'Use default',
    ),
    'relationship' => 'none',
  ),
));
$handler->override_option('arguments', array(
  'name' => array(
    'default_action' => 'ignore',
    'style_plugin' => 'default_summary',
    'style_options' => array(),
    'wildcard' => 'all',
    'wildcard_substitution' => 'All',
    'title' => '',
    'default_argument_type' => 'fixed',
    'default_argument' => '',
    'validate_type' => 'php',
    'validate_fail' => 'not found',
    'glossary' => 0,
    'limit' => '0',
    'case' => 'lower',
    'path_case' => 'lower',
    'transform_dash' => 0,
    'add_table' => 0,
    'require_value' => 0,
    'id' => 'name',
    'table' => 'term_data',
    'field' => 'name',
    'override' => array(
      'button' => 'Use default',
    ),
    'relationship' => 'none',
    'default_options_div_prefix' => '',
    'default_argument_user' => 0,
    'default_argument_fixed' => '',
    'default_argument_php' => '',
    'validate_argument_node_type' => array(
      'news' => 0,
      'page' => 0,
    ),
    'validate_argument_node_access' => 0,
    'validate_argument_nid_type' => 'nid',
    'validate_argument_vocabulary' => array(
      '1' => 0,
      '3' => 0,
    ),
    'validate_argument_type' => 'tid',
    'validate_argument_php' => '$spaced = str_replace(\'-\', \' \', $argument);
            
            if (taxonomy_get_term_by_name($argument)) { 
              // is there such a term?
              $handler->argument = $argument;  
              return TRUE;
            }
            else if (taxonomy_get_term_by_name($spaced)) {
            $handler->argument = $spaced;  
              return TRUE;
            }
            else
            {
              return FALSE;
            }',
  ),
  'date_argument' => array(
    'default_action' => 'ignore',
    'style_plugin' => 'default_summary',
    'style_options' => array(),
    'wildcard' => 'all',
    'wildcard_substitution' => 'All',
    'title' => '',
    'default_argument_type' => 'fixed',
    'default_argument' => '',
    'validate_type' => 'none',
    'validate_fail' => 'not found',
    'date_fields' => array(
      'node_data_field_publication_date.field_publication_date_value' => 'node_data_field_publication_date.field_publication_date_value',
    ),
    'date_method' => 'OR',
    'granularity' => 'month',
    'id' => 'date_argument',
    'table' => 'node',
    'field' => 'date_argument',
    'override' => array(
      'button' => 'Use default',
    ),
    'relationship' => 'none',
    'default_options_div_prefix' => '',
    'default_argument_user' => 0,
    'default_argument_fixed' => '',
    'default_argument_php' => '',
    'validate_argument_node_type' => array(
      'news' => 0,
      'page' => 0,
    ),
    'validate_argument_node_access' => 0,
    'validate_argument_nid_type' => 'nid',
    'validate_argument_vocabulary' => array(
      '1' => 0,
      '3' => 0,
    ),
    'validate_argument_type' => 'tid',
    'validate_argument_php' => '',
  ),
));
$handler->override_option('path', 'news/%/archive/%');
$handler->override_option('menu', array(
  'type' => 'none',
  'title' => '',
  'weight' => 0,
  'name' => 'navigation',
));
$handler->override_option('tab_options', array(
  'type' => 'none',
  'title' => '',
  'weight' => 0,
));
$handler = $view->new_display('block', 'News Block', 'block_1');
$handler->override_option('fields', array(
  'title' => array(
    'label' => '',
    'link_to_node' => 1,
    'exclude' => 0,
    'id' => 'title',
    'table' => 'node',
    'field' => 'title',
    'relationship' => 'none',
  ),
  'view_node' => array(
    'label' => '',
    'text' => 'Read more',
    'exclude' => 1,
    'id' => 'view_node',
    'table' => 'node',
    'field' => 'view_node',
    'relationship' => 'none',
  ),
  'field_breaking_value' => array(
    'label' => '',
    'link_to_node' => 0,
    'label_type' => 'none',
    'format' => 'default',
    'multiple' => array(
      'group' => TRUE,
      'multiple_number' => '',
      'multiple_from' => '',
      'multiple_reversed' => FALSE,
    ),
    'exclude' => 1,
    'id' => 'field_breaking_value',
    'table' => 'node_data_field_breaking',
    'field' => 'field_breaking_value',
    'relationship' => 'none',
  ),
  'field_publication_date_value' => array(
    'label' => '',
    'link_to_node' => 0,
    'label_type' => 'none',
    'format' => 'default',
    'multiple' => array(
      'group' => TRUE,
      'multiple_number' => '',
      'multiple_from' => '',
      'multiple_reversed' => FALSE,
    ),
    'exclude' => 0,
    'id' => 'field_publication_date_value',
    'table' => 'node_data_field_publication_date',
    'field' => 'field_publication_date_value',
    'relationship' => 'none',
    'override' => array(
      'button' => 'Use default',
    ),
  ),
  'field_source_value' => array(
    'label' => '',
    'link_to_node' => 0,
    'label_type' => 'none',
    'format' => 'default',
    'multiple' => array(
      'group' => TRUE,
      'multiple_number' => '',
      'multiple_from' => '',
      'multiple_reversed' => FALSE,
    ),
    'exclude' => 0,
    'id' => 'field_source_value',
    'table' => 'node_data_field_source',
    'field' => 'field_source_value',
    'relationship' => 'none',
    'override' => array(
      'button' => 'Use default',
    ),
  ),
  'field_summary_value' => array(
    'label' => '',
    'link_to_node' => 0,
    'label_type' => 'none',
    'format' => 'default',
    'multiple' => array(
      'group' => TRUE,
      'multiple_number' => '',
      'multiple_from' => '',
      'multiple_reversed' => FALSE,
    ),
    'exclude' => 0,
    'id' => 'field_summary_value',
    'table' => 'node_data_field_summary',
    'field' => 'field_summary_value',
    'override' => array(
      'button' => 'Use default',
    ),
    'relationship' => 'none',
  ),
));
$handler->override_option('block_description', '');
$handler->override_option('block_caching', -1);
$handler = $view->new_display('feed', 'Feed', 'feed_1');
$handler->override_option('sorts', array());
$handler->override_option('arguments', array());
$handler->override_option('filters', array());
$handler->override_option('items_per_page', 15);
$handler->override_option('style_plugin', 'rss');
$handler->override_option('style_options', array(
  'mission_description' => FALSE,
  'description' => '',
));
$handler->override_option('row_plugin', 'node_rss');
$handler->override_option('row_options', array(
  'item_length' => 'title',
));
$handler->override_option('path', 'feed/rss.xml');
$handler->override_option('menu', array(
  'type' => 'none',
  'title' => '',
  'weight' => 0,
  'name' => 'navigation',
));
$handler->override_option('tab_options', array(
  'type' => 'none',
  'title' => '',
  'weight' => 0,
));
$handler->override_option('displays', array(
  'default' => 'default',
  'page_1' => 'page_1',
  'page_2' => 'page_2',
  'block_1' => 'block_1',
));
$handler->override_option('sitename_title', FALSE);

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

mr.baileys’s picture

FileSize
20.04 KB

... something seems to have gone wrong posting this... second attempt (this time with the views export attached instead of embedded):

I'm trying to add the RSS feed icon to some of the displays for my view (view export included at the bottom). I have set up the "feed display" in my view (no arguments), and previewing the feed in the UI gives me the result I need.

I then attached the feed display to my other displays (some block displays, some page displays, and the "defaults"). The feed icon shows up when previewing the "defaults" display, but is missing on all the other displays to which the feed display is attached.

The "defaults" display and the other displays are using the same template file, which was copied from the views/theme directory, and contains the code to display the icon:

  <?php if ($feed_icon): ?>
    <div class="feed-icon">
      <?php print $feed_icon; ?>
    </div>
  <?php endif; ?>

When I try and dump the $feed_icon variable in my template, the result is an empty string. (except in the "Defaults"-display).

For the life of me I can't figure out why it displays fine on the default display but doesn't on any of the other displays...

Does anyone know where I'm going wrong?

merlinofchaos’s picture

Odd. The view you exported doesn't seem to actually have an 'attach to' setting for the feed display. This is usually the problem with this kind of issue report, but you specifically mentioned setting that.

I hate to ask people to check the obvious over and over, but can you please doublecheck that setting on your view and make sure it is actually set to attach to all the displays you want it to (and that the view is then saved)?

mr.baileys’s picture

FileSize
104.23 KB

Thanks merlinofchaos,

I double- and triple-checked the "attach to" settings for the feed display, and they seem to be ok (see screenshot, taken after saving the view). It's the first time I try to attach a display to another one, so I might be missing something obvious here (although I can't explain the fact that it attaches fine to the default display)

The view you exported doesn't seem to actually have an 'attach to' setting for the feed display.

Aren't these attach settings exported as:

$handler->override_option('displays', array(
  'default' => 'default',
  'page_1' => 'page_1',
  'page_2' => 'page_2',
  'block_1' => 'block_1',
));

Thanks again, appreciate any input

drewish’s picture

mr.baileys, have you tried it with the -dev release? i hadn't noticed this problem with it...

merlinofchaos’s picture

I also can't tell what might be going on here. In my own tests this is working just fine. For example, the frontpage view, which comes with Views, displays the feed icon properly.

If you want to do some further debugging, the actual data is given to the view in views_plugin_style_rss::attach_to()

As I look at this, I can see where there may be an issue with PHP4 vs PHP5. Are you using PHP4?

mr.baileys’s picture

FileSize
997 bytes

@drewish: I tried with the -dev release, but the problem persisted;

@merlinofchaos: I'm using PHP 5.2.6.
Looking at views_plugin_style_rss::attach_to() I think I found the problem though: the RSS style plugin only adds an icon for views that do not have their own path. If a view has a path (page displays), it adds meta information instead of the icon. Since views-view.tpl.php is used by page displays and contains the section to display the feed icon, I wrongly assumed that the RSS feed attachment would give me an icon...

My preference would be that an RSS feed attached to a page display would do both: add meta-data and add an icon, especially since the icon can be hidden via a template change, while adding the missing icon to a page display requires hacking into the RSS feed style plugin. Attached is the change I made to the style plugin to get the icon showing on page displays.

mr.baileys’s picture

@merlinofchaos: forgot to mention: I tried the frontpage view, and have exactly the same problem (no icon showing on the page display, icon shows up after applying the patch mentioned above)...

I also just realized that I might not have been specific enough: I am talking about an RSS icon in the body of the page, not the RSS icon that's added to the browser's address bar on page views (that one is showing up both before and after above patch).

merlinofchaos’s picture

Status: Active » Closed (won't fix)

AHH! That is your problem then. If the display has a path and it's being shown as a page, the icon is displayed *by your theme*. That's why it doesn't add the icon; if you add the icon in Garland, then the icon will be displayed twice.

This behavior is intended.

mr.baileys’s picture

Status: Closed (won't fix) » Closed (fixed)

Now it all starts to make sense. My custom theme didn't include the code to output the feed icons on pages. Thanks a lot for your time, I really appreciate it!

seanr’s picture

Category: support » feature
Status: Closed (fixed) » Needs review
FileSize
1.07 KB

The attached patch provides an additional option to display it in the attached links area instead of in $feed_icons. On a site I'm building, we're attaching a CSV view and an RSS view to a data viewer, so we want those icons to appear together at the bottom of the view.

seanr’s picture

Version: 6.x-2.1 » 6.x-2.x-dev
dawehner’s picture

Status: Needs review » Needs work

There is a need for a option_definition. If you do not do it, it will not export in 3.x

dawehner’s picture

Additional:

  • This patch does not apply to 3.x, you have to provide a patch for 3.x, too
  • You should make a option disable instead of enable. By default views provides the links, so don't confuse the user :)
seanr’s picture

Thanks. I should be able to get back to this next week. Currently using views 2 everywhere, but I'll be able to get a dev site set up with views 3 after I finish my current project.

dawehner’s picture

Status: Needs work » Needs review
FileSize
1.29 KB

Updated patch, i didn't looked at the patch, i'm not sure why this is needed

merlinofchaos’s picture

I think this option is needed because drupal's feed icons area kind of sucks, so it makes sense that we might want an alternative.

That said, I would like further review and testing before I commit this, please.

merlinofchaos’s picture

Bumping. Still needs some testing. Thanks.

merlinofchaos’s picture

Assigned: Unassigned » bojanz

Assigning to bojanz for testing.

dtarc’s picture

I needed this feature and tried the patch and it worked fine for me. Drupal 6.20 and Views 2.12.

After patching the file, I configured the setting in my view and updated the code in my feature. The feature got rolled out to our staging server where the feature was enabled. The feed link showed up in the links area.

mstrelan’s picture

+1 on #15. Works great on Drupal 6.19 with Views 6.x-2.11 and is exactly what I needed.

mstrelan’s picture

Title: Feed display attachment problem (no feed icon) » Allow views templates to display feed icons on page displays that have a path
ñull’s picture

+1
subscribing

pfaocle’s picture

Re-rolled patch for D7/Views 3.x - will have this version of the patch in a project for testing soon.

Status: Needs review » Needs work

The last submitted patch, views-allow_feed_icons_dislays_with_path-335808-23.patch, failed testing.

pfaocle’s picture

Status: Needs work » Needs review
FileSize
1.26 KB

Patch is identical to previous, just corrected typo in file name. I. Just. Had. To.

Status: Needs review » Needs work

The last submitted patch, views-allow_feed_icons_displays_with_path-335808-24.patch, failed testing.

MustangGB’s picture

Status: Needs work » Closed (won't fix)