Why does not hook_menu_link_alter() work? i want to expand my theme's primary links, so I put the following code in my custom module.

function mymodulename_menu_link_alter(&amp;$item, $menu) {
  if ($item['menu_name'] == 'primary-links') {
    $item['expanded'] = 1;
  }
}


In page.tpl.php I used print theme('links', $primary_links), but the primary links didn't expand. Why?
Not really a complete answer, but hook_menu_link_alter() is not called when the menu is rendered; it is called when the menu item is saved. Just an FYI.