Need to open native maps app on iPhone and/or android phones out of a mobile website. Currently I did this by simply open a maps.google.com link.
Since iOS6 is released this seems not working any more.
Are there any standardized or at least well known methods to accomplish opening native maps on most platforms?
If not, can I check the mobile OS to do some special things on every mobile phone?
In order to support opening the native maps app across the most recent iOS versions you’re going to have to check the type of device, as iOS 6 devices will direct users to the google maps website, rather than their native app.
The best way to detect devices is via the User-Agent HTTP header. This is documented all over the net with front end javascript device detection, or back end device detection. How you approach the detection is up to your own implementation.
You can continue to use maps.google.com for everything other than iOS 6 I believe and Apple have documented their iOS6 Maps URL scheme in their Map Links documentation.
An example of an Apple Maps link would be