What is the difference between event.PreventDefault and event.stopPropagation?
Answer / chaitanya
event.preventDefault(): Stops the default action of an element from happening.
event.stopPropagation(): Prevents the event from bubbling up the DOM tree, preventing any parent handlers from being notified of the event. For example, if there is a link with a click method attached inside of a DIV or FORM that also has a click method attached, it will prevent the DIV or FORM click method from firing.
| Is This Answer Correct ? | 0 Yes | 0 No |
How to write browser specific code using jQuery?
What are the browser related issues for jQuery?
Can we have multiple document.ready() function on the same page?
What is the difference between size and length of jQuery?
Explain chaining in jquery? : jquery mobile
What does dollar sign ($) means in jquery? : jquery mobile
Can we use protocol less URL while referencing jQuery from CDNs?
Why we use chaining in jquery?
What is the advantage of using minimized version of jQuery?
What is a jquery ?
Is jquery a library for client scripting or server scripting? : jquery mobile
What is the purpose of fadetoggle() method in jquery?