views:

349

answers:

4

jQuery uses event bubbling strategy to handle events.

And it claims to be cross browser,

but is "event bubbling" supported by all browsers?

There is another strategy: event capturing, which is reverse to event bubbling,is it extinct?

Or my question could be re-stated as:

Can Javascript decides on whether choosing "event capturing" strategy or "event bubbling" strategy by itself?

+5  A: 

All browsers? No. Lynx, for instance, doesn't support JavaScript at all.

However, event bubbling is a standard DOM feature. The jQuery documentation is not lying to you.

David Dorward
Don't forget there is also event capturing strategy,where is it used or is it extinct?
Shore
A: 

In short, yes. Netscape Navigator 4 doesn't support it, but I don't think there's a lot of worry about supporting Netscape 4 these days.

hobbs
A: 

Either they are lying, or the definition for "Cross-Browser" needs to be slightly altered. It's either cross-browser or it isn't there's no in-between.

baeltazor
The "Cross Browser" heading on the jQuery homepage clearly shows what it means if you hover it, and there are further details under "Supported Browsers" in the docs. To summarize, every significant browser for desktop platforms released in the past several years is supported, with many older or less common browsers working just fine (but without being specifically supported targets).
hobbs
"every significant browser"... Then it's not completely cross-browser is it? ... No, it isn't.
baeltazor
It runs on more than one browser. Therefore it is cross-browser. The only thing that needs altering is your misunderstanding of the phrase.
hobbs
um no...Web definitions for Cross-browser Cross-browser refers to the ability for a website, web application, HTML construct or client-side script to support all the web browsers. ...en.wikipedia.org/wiki/Cross-browser - Definition in context
baeltazor
ALL THE WEB BROWSERS??? Do you know about Lynx?
Camilo Martin
+2  A: 

From the jQuery compatibility page, it supports the following browsers:

  • Firefox 2+
  • IE6+
  • Safari 3+
  • Opera 9+
  • Chrome 1+

All of which support event bubbling.

According to the W3Schools browser usage page those browsers account for 99.2% of all browser usage in July 2009, I'd say this is cross-browser support covered. Ignore those peddling pointless pedantry about browser support being all or nothing. If you're a user of any other browser you are probably far enough from the mainstream to have your own methods of dealing with browser issues.

Rich Seller
My main concern now focuses on how javascript chooses to hook on "event capturing" or "event bubbling" phase of model?
Shore