domingo, 6 de enero de 2013

Windows Phone Doesn’t Support Google Maps Because Google Doesn’t Want It To

The situation regarding accessing Google Maps on Windows Phone devices is about vendor choice, not browser capabilities.

Let's try this again. Yesterday, a number of reports surfaced that Windows Phone users were unable to access Google Maps in the browser. Instead of reaching the Maps page, users are automatically redirected to the main Google homepage. This is true both for users attempting to access Google Maps from the mobile or desktop view in Internet Explorer on Windows Phone 7.X and Windows Phone 8 devices.

Google's official response -- as we pointed out yesterday -- is that the decision to redirect users away from Google Maps on Windows Phone devices is a choice Google has made.

Google's official response -- as we pointed out yesterday -- is that the decision to redirect users away from Google Maps on Windows Phone devices is a choice Google has made. That's because it has optimized the mobile version of its Maps website for browsers that use the WebKit rendering engine. WebKit is the rendering engine that Apple, Google, RIM and many others use on their mobile browsers. Meanwhile, Microsoft uses the Trident rendering engine for Internet Explorer on the desktop and mobile.

While Trident -- especially with Internet Explorer 10 -- is highly compliant with HTML5, CSS3, JavaScript and other web standards, Google has made optimizations to its mobile maps site that specifically target WebKit. As a result, it's possible that some of those optimizations won't render correctly on a non-WebKit browser, such as Internet Explorer.

As many users have pointed out, Google Maps works just fine on Internet Explorer for the desktop. Microsoft's official comment is that Internet Explorer 10 uses the same rendering engine as Internet Explorer on Windows Phone 8. If IE 10 can render a page, Windows Phone 8 should be able to render that page equally well.

Believe it or not, this is still in line with Google's own comments on the matter. The desktop version of Internet Explorer serves the standard version of Google Maps without a problem at all. This is about the mobile website.

When I tried to explain the situation yesterday, I failed to properly clarify that this is not about whether or not Internet Explorer is capable of displaying Google Maps. Instead, it's about Google's decision not to support non-WebKit mobile browsers.

To wit, changing the user agent on the Windows Phone simulator to something that doesn't say Windows Phone or identifies itself as Internet Explorer for Windows Phone renders the desktop version of Google Maps without a problem.

I should also clarify that Google is going one step further and also blocking access from the "desktop" mode on Windows Phone. To me, this is going too far. It's one thing to not support the mobile view; it's another to remove to ability to access the site even with the desktop view in place.

It's Not Just Windows Phone

Windows Phone isn't the only mobile platform that is experiencing redirects from Google Maps. In non-WebKit browsers on Meego and Symbian, I saw the same results. I also re-confirmed these results with a user agent switch on a desktop browser.

Interestingly, Firefox for Android and the FirefoxOS simulator both work with Google Maps -- at least for now. This is despite the fact that Firefox uses the Gecko rendering engine, not WebKit. The last time I tested Firefox for Android back in June, I ran across a number of different errors accessing Google-specific mobile pages. It remains to be seen if Google will continue to support its WebKit-only views on Firefox for Android in the future.

Google Should Follow Its Own Best Practices

While I respect Google's right to block mobile access from non-WebKit browsers, I do wish the company would have chosen to follow its own best practices when doing these redirects.

According to its own best practices, Google discourages user-agent sniffing to control what type of website is displayed. Instead, Google (and other web experts) recommend that web developers detect for specific feature support, rather than the user agent.

What I suspect is really happening is that Google is phasing out support for its WAP-based mobile maps and is focusing all of its mobile efforts on WebKit. As a result, non-WebKit (or whitelisted) browsers on mobile devices are going to lose access to Google Maps, regardless of how capable the browser rendering engine may or may not be.

Could Google Maps for Mobile Work on Windows Phone?

As earlier tests have shown, Google Maps, at least the desktop view, appears to work just fine on Windows Phone.

What I have not been able to test and confirm is how well Google Maps would work on a Windows Phone device if the user agent was changed to WebKit instead. While spoofing a user agent string is generally discouraged behavior, this would be a way to look at how the WebKit-optimized mobile code runs on the non-WebKit IE browser.

I suspect there are some very real usability problems -- based on my own experiences with WebKit-optimized mobile sites on Windows Phone -- but I'd like to confirm the situation one way or another. If you have access to the Windows Phone emulator and want to try out that sample app, let me know what you find out. As soon as I'm back in the office with a Windows dev environment, I can test this myself.

Sound off in the comments with your thoughts about this whole user agent snafu.

Image courtesy of Nokia and Google, composite by Mashable

No hay comentarios:

Publicar un comentario