trying to display the second level menu

Hello,
I'm using this code that I found in the handbook:
<?php// allows to display icons with the primary linksfunction primary_links_add_icons() {  $links = menu_primary_links();  $level_tmp = explode('-', key($links));  $level = $level_tmp[0];  $output = "<ul class=\"links-$level\">\n";     if ($links) {    foreach ($links as $link) {       $link = l($link['title'], $link['href'], $link['attributes'], $link['query'], $link['fragment']);       $cssid = str_replace(' ', '_', strip_tags($link));       $output .= '<li id="'.$cssid.'"><span class="menu-hidden-text">' . $link . '</span></li>';    };    $output .= '</ul>';  }  return $output;}?>
I'm trying to get it to show the 2nd level of the primary links, but when I try to modify the menu_primary_links , it doesn't work.
any one know how I can get the 2nd level too?
thanks
Idan

Advertising