Followed the steps in README.txt (though some paths are changed for D7).

Downloaded and installed Nice Menus, ran update.php. Enabled module and saved settings. In Admin/Config there is no field to specify the parent menu to use. In Blocks->Nice Menu 1->Config the pulldown for parent menu is empty.

Unable to proceed further without either bugfix or documentation correction.

CommentFileSizeAuthor
#3 nice_menus_987530.patch1.72 KBe-m-h

Comments

SolaFide001’s picture

Title: Unable to configure Nice Menus in Admin » Unable to configure Nice Menus in Admin (update)

My D7 install is actually an upgrade of a D6.x site. I also have a pure D7b3 install.

On the upgrade site, the menu uses the D6.x naming - Primary Links, but the pure D7 site has "Main Menu" instead. Perhaps Nice Menu 7.x relies on the new name?

jcarlson34’s picture

I also upgraded from D6 and am now using D7RC2 and the 7.x-2.0-dev version.

My dropdown field is also empty. I was able to get the drop down menu to show by changing line 208 in the nice_menus.module from:

'#options' => menu_parent_options(menu_get_menus(), 0),
to
'#options' => menu_get_menus(),

line 242 from

list($menu_name, $mlid) = explode(':', variable_get('nice_menus_menu_' . $delta, 'navigation:0'));
to
list($menu_name) = explode(':', variable_get('nice_menus_menu_' . $delta, 'navigation:0'));

and line 245 from

if ($output = theme('nice_menus', array('id' => $delta, 'menu_name' => $menu_name, 'mlid' => $mlid, 'direction' => $direction, 'depth' => $depth))) {
to
if ($output = theme('nice_menus', array('id' => $delta, 'menu_name' => $menu_name, 'direction' => $direction, 'depth' => $depth))) {

This is probably the wrong way to do it as I'm terrible with PHP but it returned the dropdown menu and I was able to choose from the list.

Not sure why menu_parent_options(menu_get_menus(), 0), isn't working because there wasn't an API change between D6 and D7 for that function...

e-m-h’s picture

Component: Documentation » Code
Status: Active » Needs review
StatusFileSize
new1.72 KB

Had the same issue with a fresh D7 and Nice Menus install. Tried the changes posted by jcarlson34, these worked for me. Not a code expert here so can't validate if these changes are right or wrong. All I know is that it solved my issue.

In any case attached is a patch implementing these changes. Likely not a final solution, but works in the meantime.

jcarlson34’s picture

Ah a patch is much better than my post. Thanks emh.

At some point I've got to learn how to make those things... :)

Augusto182’s picture

Hello. (i dont speak inglish)

Im using drupal 7, and istall the beta aviable for this module.

I try the changes, and yes, im able to choose the correct menu for the nice menu block.

BUT...

I cant access to the settings, and cant able the js options (superfish).

Tanks a lot.

(pdt: any other menu module for drupal 7)

juhaniemi’s picture

Subscribe. No "Menu Parent" options available on a Drupal 6 => 7 upgraded site. Works on a vanilla D7 site.

add1sun’s picture

Status: Needs review » Fixed

Committed to HEAD.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.