how can i write a conditional comment for scripts that should run for all browsers except IE 8 and below?
i saw Conditional comment for 'Except IE8' ?
but how do i adapt it to include scripts files not inline scripts?
how can i write a conditional comment for scripts that should run for all browsers except IE 8 and below?
i saw Conditional comment for 'Except IE8' ?
but how do i adapt it to include scripts files not inline scripts?
The trick explained there would work just as well for external scripts — set a "this browser is old" flag in a conditional-commented inline script, and have your external scripts check for that flag.
If you mean to conditionally include entire script files, your best bet would probably be a script that browser-sniffs and dynamically includes the appropriate files. Otherwise, you could use downlevel-revealed conditional comments (thanks, bobince!).