' . t('Legend:') . '
'; $output .= '' . theme('site_map_feed_icon', array('type' => 'node')) . ' ' . t('Link to a content RSS feed'); $output .= '
' . theme('site_map_feed_icon', array('type' => 'comment')) . ' ' . t('Link to a comment RSS feed'); $output .= '

'; return $output; } /** * Preprocesses the variables for theme_site_map_box(). */ function template_preprocess_site_map_box(&$variables) { $variables['attributes']['class'][] = 'site-map-box'; } /** * Returns HTML for a themed site map box. * * @param array $variables * An associative array containing: * - title: The subject of the box. * - content: The content of the box. * - attributes: Optional attributes for the box. * * @return string * Returns sitemap display in DIV. */ function theme_site_map_box($variables) { $title = $variables['title']; $content = $variables['content']; $attributes = $variables['attributes']; $options = $variables['options']; $output = ''; if (!empty($title) || !empty($content)) { $output .= ''; if (!empty($title) && isset($options['show_titles'])) { $output .= '

' . $title . '

'; } if (!empty($content)) { $output .= '
' . $content . '
'; } $output .= ''; } return $output; } /** * Returns HTML for a feed icon with link. * * @param array $variables * An associative array containing: * - url: The url of the feed. * - name: The name of the feed. * - type: The type of feed icon. * * @return string * Constructs and returns html with feed image icon. */ function theme_site_map_feed_icon($variables) { $output = ''; switch ($variables['type']) { case 'node': $output = theme('image', array( 'path' => drupal_get_path('module', 'site_map') . '/feed-small.png', 'alt' => t('Syndicated feed icon'), ) ); break; case 'comment': $output = theme('image', array( 'path' => drupal_get_path('module', 'site_map') . '/feed-small-comment.png', 'alt' => t('Syndicated feed icon'), ) ); break; } if (!empty($variables['url'])) { $output = l($output, $variables['url'], array( 'attributes' => array( 'class' => array('feed-link'), 'title' => t('Syndicated feed for') . ' ' . $variables['name'], ), 'html' => TRUE)); } return $output; } /** * Preprocesses the rendered tree for theme_site_map_menu_tree(). * * This is a clone of the core template_preprocess_menu_tree() function * with the exception of the site_map specific class name used in the * UL that also allow themers to override the function only * for the site map page. */ function template_preprocess_site_map_menu_tree(&$variables) { $variables['tree'] = $variables['tree']['#children']; } /** * Returns HTML for a wrapper for a menu sub-tree. * * This is a clone of the core theme_menu_tree() function with the exception of * the site_map specific class name used in the UL that also allow themers to * override the function only for the site map page. * * @param array $variables * An associative array containing: * - tree: An HTML string containing the tree's items. * * @return string * Returns the html string with the