Question

Hi all here is my question

I am using jquery accordion in my website.

I was trying to add a small slide down menu in to the accordion head it is coming fine but the problem is whenever I am clicking the menu, my slide down mu is coming and the same time accordion is also expanding.

I don't want accordion to be activated when I am clicking the small menu icon

enter image description here

Was it helpful?

Solution

Use stopPropagation, which will prevent the click from bubbling up to the accordion's click handler:

$('.small-menu-icon').click(function(e) {
    e.stopPropagation();
    // show menu
});
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top