JavaScript and browsers compatibility

Hi,

I am more a php and python developper, and my new project has to use use JavaScript and jQuery as programming language. My question is: Based on your experience, is the combination of JavaScript and jQuery the best choice for cross browser compatibility?(IE, Firefox, Chrome and safari)

Thanks your input,

The term “cross browser compatibility” is more of a CSS thing since jQuery creates polyfills for older browsers such as IE to keep a consistent experience, depending on what types of things your project needs to accomplish you can sometimes get away with smaller libraries for animations, events, DOM selection etc., but most of the time vanilla JavaScript will work perfectly fine in older browsers such as IE7.

  1. JQuery is just a library of JavaScript routines so using or not using JQuery makes no difference.

  2. There was a new version of JavaScript introduced in late 2011. Older browsers - particularly Internet Explorer - do not support all the new commands that version introduced although the more important of the new commands (such as “use strict”) were implemented in a way that means that the code will still work even if the browser doesn’t understand it. With the new commands that older versions of IE don’t understand you can use feature sensing to identify where a command isn’t recognised and either skip over the code or implement your own version of the command.

As far as providing interactive behaviour in a web browser JavaScript is the only choice because it is the only language that all modern browsers understand that is actually built into the browser itself and which therefore most people will have turned on. The only alternatives require that a plugin be downloaded and installed into the browser and turned on before it can be used.

I made a board about this topic, relating to my issues with Javascript in IE. I think it may be of some use for you, here you go. http://www.verious.com/board/AKumar/javascript-not-working-with-ie8/