I'm using a wildcard menu item, the menu is disappearing.

browse/%letter

In runtime the links are generated by the letter_to_arg function from menu module. Because of the wildcard, no menu href is in the menu links table. But the path exists.

Changed the code to display the menu correctly for wildcards:

// Get the menu link and set the active menu to the menu it's in, so Drupal can find it's way and make correct breadcrumbs at the same time
$link = menu_link_load(db_result(db_query("SELECT mlid FROM {menu_links} WHERE link_path = '%s' AND hidden <> 1", $item['href'])));

if($link == null)
$link = menu_link_load(db_result(db_query("SELECT mlid FROM {menu_links} WHERE link_path = '%s' AND hidden <> 1", $item['path'])));

added the 2 lines...