menu_navigation_links() generate a error I'm try listing a menu navigation links with menu_navigation_links() function, but is generate a follow error:


  Notice: Undefined index: localized_options in menu_navigation_links() (line 1860 of /home3/xptoboxc/public_html/drupal/includes/menu.inc).


My code:

$html .='&lt;ul id="navigation" class="arrow-list"&gt;';
foreach (menu_navigation_links('navigation') as $menu =&gt; $link) {
    if(!empty($link['title']))
        $html .= '&lt;li&gt;&lt;a href="' . url($link['href']) . '" title="' . $link['title'] . '"&gt;' . $link['title'] . '&lt;/a&gt;&lt;/li&gt;';
}
$html .= '&lt;/ul&gt;';
Are you using the navigation menu as the secondary menu for the site?

The cause could be a bug in drupal core. See http://drupal.org/node/1018614

There is a patch in #83, which I think is for drupal 8 but the fix should be the same for drupal 7.