Remove theme information from not theme function

drupalnuts - May 22, 2009 - 20:47
Project:Paging
Version:6.x-1.0-beta3
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:active
Description

Please remove

  return '<div class="links">' . $output . '</div>';

from the code below and replace it with
return $output;

We can move the div into the theming layer were it belongs. My issue is that I am already using a links name for something else in the node.tpl.php. I would expect to be able to override this, but I can not because this is not a themeing function.
Thanks!

function paging_pager_style($node = NULL, $element = NULL) {
  $theme_widget = variable_get('paging_pager_widget_' . $node->type, 'pager');

  if ($theme_widget == 'custom') {
    // Load the custom user function.
    $theme_widget = variable_get('paging_pager_widget_custom_' . $node->type, 'pager');
  }

  if ($theme_widget == 'paging_drop_down') {
    // Include CSS for 'Drop down pager' styling.
    drupal_add_css(drupal_get_path('module', 'paging') . '/paging.css', 'module');
  }

  // Decode the comma entity.  
  $output = str_replace('%2C', ',', theme($theme_widget, NULL, 1, $element, array(), 9, $node->page_names));

  return '<div class="links">' . $output . '</div>';
}

 
 

Drupal is a registered trademark of Dries Buytaert.