https://jsfiddle.net/cr72vqhb/1/

Follow 2 scenario's.

First Scenario:
Click on client-side, get message, menu slides out.
Click on server-side, get message, first menu hides, second slides out.
Perfect, right?

Hard refresh the Fiddle

Second Scenario:
Click on server-side, nothing. Absolutely nothing. It's as if I mistyped the selector.

Why is this happening? server-side can be only triggered once client-side has been triggered.

Member Avatar for diafol

https://jsfiddle.net/cr72vqhb/2/

Not quite what you want but it's the first "nav div" animate (in your first fiddle) that's the problem. If you comment out this line - yes submenus are visible, but the clicks work as expected.

Your code does work and it does provide the solution.
Unfortunately I still don't understand what the problem was about.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.