Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What is the difference between event.PreventDefault and event.stopPropagation?

Answer Posted / 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



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Does jquery follow w3c recommendations?

883


How to increase cursor size in html body using jquery?

800


Difference between parent() and parents() in jQuery?

930


How to disable/enable an element in jquery?

963


Back onto jquery ui' can you see jquery ui making more of an impression in the future, lead by the current successes of jquery?

915


Can you please explain the difference between parent() and parents() methods in jquery? : jquery mobile

807


Is jQuery a programming language?

888


Define animate function in jquery?

856


What are the two types of CDNs?

1022


Explain the difference between event.preventdefault and "return false"? : jquery mobile

849


What is the use of the animate() method in jquery?

848


How can we apply css in div using jquery?

958


Explain the use of data-role=”page” attribute? : jQuery Mobile

859


How to revert the most recent ‘destructive’ operation, changing the set of matched elements to its previous state using ?

873


What are the different types of selectors?

892