Answer the question
In order to leave comments, you need to log in
How to fire js events for graphicon icon from bootsrap 3 in firefox?
For example
, there is a button with an icon, when you click on the button, one event should occur, and when you click on the icon, another. Everything works perfectly in chrome, problems with firefox. Maybe someone knows the solution to this problem?
Answer the question
In order to leave comments, you need to log in
What is the problem with firefox?
If you now set a click catch on .btn in your example, then when you click on an asterisk, it will also work, because event bubbling, i.e. the event "bubbles" from deeper DOM elements to the root and fires all handlers that are set on parent elements.
Bubbling in jquery is prevented by returning false from the handler function.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question