After enabling submenu tree for a node I need a CSS class for changing the look of the submenu.
In submenutree.module I changed 2 lines (498,499)
function theme_submenu_tree_menu($tree, $title = null) {
$output = '';
if (isset($title))
$output .= '<h3>'. $title .'</h3>';
$output .= menu_tree_output($tree);
return $output;
}
in
function theme_submenu_tree_menu($tree, $title = null) {
$output = '';
if (isset($title))
$output .= '<div class="submenu-tree">'.'<h3>'. $title .'</h3>';
$output .= menu_tree_output($tree).'</div>';
return $output;
}
I am not a professional-coder, so I don't know how to make a patch for this. I also don't know if other parts of the script needs changes.
I don't like changes in original module script and I think this could be usefull for others.
regards
Martin
Comments
Comment #1
bengtan commentedYou can override the output of submenutree by using your theme. See http://drupal.org/node/341628.
Essentially, you create your own version of theme('submenu_tree_menu', ...) and change that to do as you like.
Comment #2
Anonymous (not verified) commentedThanks for pointing me to a better way of overriding the output. I made my changes in template.php.
Martin