For some reason nice menus fail to filter menu items based on the current language and display all the items in the menu whatever language setting they have.

Comments

judgedrid’s picture

Answering to my own question, i modified the code a bit to support the i18nmenu module

function theme_nice_menu_build($menu) {

	$output = '';


	foreach ($menu as $menu_item) {
		if (module_exists(i18nmenu))
		{
			global $language;
			$lang_match=($menu_item['link']['options']['langcode']==$language->language || $menu_item['link']['options']['langcode']=='');
		}
		$mlid = $menu_item['link']['mlid'];
		// Check to see if it is a visible menu item.
		if (($menu_item['link']['hidden'] == 0) AND $lang_match) {
add1sun’s picture

Status: Active » Closed (duplicate)

This feature is added in the 2.x version (note that menu translation is not in core, so this is not a bug, but a feature.) #300628: Support menu translation (i18n)