I'm using Gears which works well in FF3 and Safari; IE6/7 both report a "google is undefined" error on page load, appearing in gears_init.js. A quick web search showed that Javascripts by Google are actually causing problems in IE7. Does anybody have an idea for a workaround?
相关问题
- Is there a limit to how many levels you can nest i
- How to toggle on Order in ReactJS
- How to fix IE ClearType + jQuery opacity problem i
- void before promise syntax
- Keeping track of variable instances
This is probably because IE6/7 don't have gears installed. That means the google related code won't be available.
You probably just want to do something like:
Though in reality you'd want to do something a bit nicer than showing an alert to tell the user to download gears.
I am using IE8 and I am writing following code, that works fine in Mozilla Firefox but can't working in IE8
The first condition
!window.google
is working fine but second condition!google.gears
didn't work for IE8, said google is undefined