Am I doing something wrong or is this not supported yet?

Comments

dhalbert’s picture

They work for me on an iPod Touch running iOS 4.1.2 and an iPad running iOS 5.0.1. I tried turning the Javascript setting on and off, and it makes no difference. I'm using a horizontal menu and vertical dropdowns.

jonathan_hunt’s picture

Nice Menus doesn't work for me on iOS 5 (iPhone 4). I can select the top menu items only but there is no way to reach the menu items below. I wonder what the correct behavior should be though...

[Edit: on further testing, it looks like a *very* quick tap on a top menu-item will reveal submenu, so Nice Menus does work on iOS though the usability isn't great.]

Patricia_W’s picture

Category: feature » bug
Priority: Major » Minor

I'm also having a problem with nice menus on ios5. Although I have specified horizontal menus and it appears correctly on my desktop when I view it on my iPhone the menu is vertical.

DERIIIFranz’s picture

I'd would also very appreciate if someone would improve the usability for iOS as jonathan_hunt mentioned!! (i'm using vertical menus)

ayushjn’s picture

Facing the same issue. The menu is looking absolutely fine on my laptop but is not present at all when I view it on ipad. Any help in this regard is highly appreciated.

brightbold’s picture

Same problem here. I can get the first level of dropdowns to work fine, but if you have nested levels those don't work. When I tap an item in my horizontal menu (1st level), the dropdown (2nd level) appears, and if I tap an item there that has a submenu, the submenu (3rd level) appears but meanwhile I am being redirected to the 2nd level page I tapped on - once I was able to tap the 3rd level menu item quickly enough to go to that page, but I couldn't do it again. And a 4th level page would be impossible.

Patricia_W’s picture

I have the same issue with Superfish menus in iOS6.

Patricia_W’s picture

In case it wasn't clear, I meant the superfish menus generated by the Superfish module.

omd’s picture

Version: 7.x-2.0 » 7.x-2.1
Priority: Minor » Critical

I'm having the same issue as #6 BrightBold. Although you can get a glimpse of the 3rd level nested menu on iOS devices, it disappears so quickly you can't select any of the items and you end up on the parent menu page instead.

Devjuh’s picture

I found de following code

// see whether device supports touch events (a bit simplistic, but...)
var hasTouch = ("ontouchstart" in window);
var iOS5 = /iPad|iPod|iPhone/.test(navigator.platform) && "matchMedia" in window;
 
// hook touch events for drop-down menus
// NB: if has touch events, then has standards event handling too
// but we don't want to run this code on iOS5+
if (hasTouch && document.querySelectorAll && !iOS5) {
    var i, len, element,
        dropdowns = document.querySelectorAll("#menu li.children > a");
 
    function menuTouch(event) {
        // toggle flag for preventing click for this link
        var i, len, noclick = !(this.dataNoclick);
 
        // reset flag on all links
        for (i = 0, len = dropdowns.length; i < len; ++i) {
            dropdowns[i].dataNoclick = false;
        }
 
        // set new flag value and focus on dropdown menu
        this.dataNoclick = noclick;
        this.focus();
    }
 
    function menuClick(event) {
        // if click isn't wanted, prevent it
        if (this.dataNoclick) {
            event.preventDefault();
        }
    }
 
    for (i = 0, len = dropdowns.length; i < len; ++i) {
        element = dropdowns[i];
        element.dataNoclick = false;
        element.addEventListener("touchstart", menuTouch, false);
        element.addEventListener("click", menuClick, false);
    }
}

Paste this code into the nice_menu.js
This works fine for me!

omd’s picture

#10 This did not change anything for me.

omd’s picture

Having the same issue and #6.

xiukun.zhou’s picture

Hi guys,

about superfish v1.7.2: http://users.tpg.com.au/j_birch/plugins/superfish/

Try this in nice_menus-7.x-2.3:

use hook_library_alter(). update superfish to 1.7 then usejquery update module update jquery version.

digitalecartoons’s picture

Issue summary: View changes

Doesn't work for me in iOS either. Both not on my iPhone 4 (with iOS7) and any iPad. Tapping on any menu only shows the secondary menu in a flash. That secondary menu then immediately disappears again. Can that be fixed soon please?

Update: I discovered the Jquery Update module and updated my Drupal 7 Core to the latest Jquery version with it (1.8). Which seems to solve the problem. Upon tapping my primary menu link, all secondary menu links drop down. And stay dropped down. It doesn't go back up again after a second like on a normal computer. Unless I tap other menu items. Which is in any case better than all links disappearing in a flash when the primary link has been tapped.

Perhaps in a next update it could be added that just like on a computer, the expanded secondary menu closes again in the set amount of milliseconds on an iOS device too?

In any way, updating Jquery solved iOS problem for me.

xiukun.zhou’s picture

miniwebs2’s picture

#14 Works - thank you!

xiukun.zhou’s picture

Status: Active » Fixed

Status: Fixed » Closed (fixed)

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

ameer khan’s picture

#14... its working after changing jquery to 1.8 but current menu is not working.