Reputation: 2236
I'm developing a system, where the user is able to design their websites - either using ready-made templates or designing templates from scratch. I'm about to complete the system and it is compatible with Firefox. For this system, I have used jQuery drag-and-drop plug-ins, TinyMCE, range object and stylesheet DOM object. As of now, it works properly with Firefox, but I need to make it work smoothly on IE8, IE7, Safari and Chrome. I'm a bit confused here about how to handle the whole JS section for all the browsers.
I'm thinking of two options -
Kindly suggest which approach will be better to make the system consistent and stable.
Upvotes: 0
Views: 975
Reputation: 943537
Then you shouldn't have much code that is specific enough to any browser to justify serving up different scripts.
Upvotes: 1
Reputation: 318508
Use jQuery or another library to write browser-independent code. You shouldn't need any browser-specific JS - only browser-specific CSS depending on what you do. And since usually only IE needs that you can easily embed a second CSS file only for certain IE versions using conditional comments.
Upvotes: 0