There is an issue when the navigation is empty, the module still returns the DIV tags even when there are no links and there is no tree.
It's caused by line 514, 516 and 520 (may be a couple out - I've patched my version) which tests to see is the $tree and $links variable are set. The $links variable is always set because it's initialised on line 497 - I haven't checked to see if this is also true for $tree.
I've changed all of these isset() tests to !empty() and that solves the issue. Strictly speaking perhaps it should test isset() and !empty().
My new code is:
if (!empty($tree) || !empty($links)) {
$output = '<div class="book-navigation">';
if (!empty($tree)) {
$output .= $tree;
}
if (!empty($links)) {
$output .= '<div class="page-links">'. $links .'</div>';
}
$output .= '</div>';
}
The sympton is that the style renders the DIV tags with a top and bottom border so you have unused space with two lines across the bottom of the page.
Hope this helps.
David
Comments
Comment #1
magico commentedConfirmed.
Comment #2
stevenpatzStill an issue?
Comment #3
stevenpatzStill an issue?
Comment #4
davidredshaw commentedYes - the code is unchanged in 5.1.
Comment #5
brianV commentedStill an issue in D6 or D7?
Comment #6
dpearcefl commentedConsidering the lack of activity on this issue and that Drupal v5 is no longer supported by fixes or patches, I am going to close this ticket.