I need to determine that the user has selected a sub-menu item rather than the top level item, and I'm having real trouble in determining that within the select event.
I tried
But the problem I have is that if the user clicks on the top level menu and then clicks on it again, it triggers the event, and subsequently using:
contains all the sub-menu items.