Titles Only view has a bug the theme_submenu_tree_titles function. It doesn't output links to pages. For example, if you have a page: /node/25, it will only output: /node - completely missing the: /25

On line 408 it has this line: $list[] = l($item['node']->title, 'node/' . $child->nid);

This is calling $child->nid. There is no reference to $child within this function. I was able to resolve the issue by placing this directly above the call: $child = $item['node'];

Now, the function looks like this:

function theme_submenu_tree_titles($items, $title = null) {
  $list = array();
  foreach ($items as $item) {
    $child = $item['node']; // bug fix
    $list[] = l($item['node']->title, 'node/' . $child->nid);
  }
  return theme('item_list', $list, $title);
}

Comments

bengtan’s picture

Assigned: Unassigned » bengtan
Status: Active » Needs review

Hi,

Thanks for this. I've commited a fix onto the Drupal-5 branch.

It's a slightly different fix from yours, but both will work all the same.

bengtan’s picture

Status: Needs review » Fixed
Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.