Launch google map from mobile Browser - dictionary

I was using "google local" on NOKIA 6800 browser
the search result page had a link "view on map?"
Clicking on it launched Google Maps application, and map centered on the location
of the search result.
how it is done?? Javascript ?? I have seen similar behavior in Iphone

For a static map you can use:
http://maps.google.com/maps/api/staticmap?center=kerstendalseweg%2017,berg%20en%20dal,%20nederland&zoom=14&size=400x400&sensor=false
Wrapped in an anchor for use in a HTML page:
Go to Vette BSO
For starting navigation I used this (with start en destination address)
Go to Vette BSO
From google maps API docs:
You can also easily link to Google Maps for driving directions. We suggest you use the following format for driving directions on Google Maps:
http://maps.google.com/maps?saddr={start_address}&daddr={destination_address}

It depends what mobile you use.
On Android you can use either http://maps.google.com/maps? prefix or geo:lat,long? prefix in url.
Invoking Google Applications on Android Devices
On Iphone you can use comgooglemaps://? prefix:
Google Maps iOS URL Scheme
To detect mobile device type use the following java script (this one detects iPhone or iPad):
if ((userAgent.indexOf('iPhone') != -1) || (userAgent.indexOf('iPad') != -1) )
window.location = "comgooglemaps://?saddr=london&daddr=manchester"

Related

How to detect a specific console output?

<script src="https://cdnjs.cloudflare.com/ajax/libs/UAParser.js/0.7.19/ua-parser.min.js"></script>
<script>
var ua = new UAParser();
var result = ua.getResult();
console.log(result.device);
</script>
This code gets the name of the device used by a user and displays it in the console. How do I use that information to display a different webpage depending on the device used? If the device is not a mobile device it doesn't display anything in the console. I only want it to go to a different page when it is a mobile device. I need this so I can show a mobile version of my website when the user is using a mobile device.
(Code is not mine got it from here: https://codewithmark.com/mobile-detect)
if (result.device.model != undefined){document.location="https://google.com";}

Why iframe is not loading all webpages in winjs app?

Hi All,
I took a blank WinJS Store app and placed the below code in default.html file
<iframe src="http://www.google.com" height="400" width="400"></iframe>
But the iframe is not loading the google home page. The page is left blank. While if I replace the src value to "http://www.palermo4.com" its working fine. Why is this strange behavior. Do we need to acquire any other permissions kind of thing for some urls? Kindly help me out.
Thanks in Advance
You can't load ooogle in iframe,since they are blocking this facility.
You can use Iframe for some other sites,but you won't get full controll of their JS[Loading sites] ,may have to face some breaking point in such sites.
if you really want to load google try this,.
1. Make your default browser as IE10.
2. trigger an event.
function openYourLink(){
var url = new Windows.Foundation.Uri("http://www.google.com")
Windows.System.Launcher.launchUriAsync(url);
}
In Windows 8.1 you'll also be able to use the webview control which is not sensitive to frame-busting code that sites like Google use.

Google Map API 3: Display marker tooltip (title) by default

Is it possible to display the marker tooltip (the title) by default in Google Map API 3? (Not the info windows)
Tooltip displaying is browser's behavior - it is impossible to call it with JS.
I using this library : http://code.google.com/p/google-maps-utility-library-v3/wiki/Libraries and happy with the result. For those looking similar should try this.

KML Layers Cursor CSS - Google Maps API v3

I've run into a small problem with the semi-new KML Overlay functionality with Google Maps API v3, wherein while I am able to use "suppressInfoWindows: true;", the cursor still appears as though the overlay(s) are clickable.
Is there a way at this time to change the css on the overlay(s) so that the cursor is the default cursor, so that they are purely visual, and don't confuse the user?
You can do this through javascript (not sure about a purely CSS solution) using something along the lines of...
var ctaLayer = new google.maps.KmlLayer({
url: 'myKmlFile.kml',
suppressInfoWindows: true
});
if (ctaLayer.suppressInfoWindows) ctaLayer.setOptions({clickable:false});
ctaLayer.setMap(map);
This sounds like a bug. You should file it at the Google Maps API's issue tracker.

Why map control is not appearing in windows mobile 6

I developed one asp.net web site with functionality of finding route, find place
through bing map control.
My Problem is when I am opening this web site from windows mobile with internet explorer 6.
All controls are appearing but map control is not appearing why?
<script charset="UTF-8" type="text/javascript" src="http://ecn.dev.virtualearth.net/mapcontrol/mapcontrol.ashx?v=6.2&mkt=en-us">
</script>
<script type="text/javascript">
function OnPageLoad()
{
var myMap = document.getElementById("myMap");
var LA = new VELatLong(41.2666452, -96.0011320,VELatLong.RelativeToGround);
myMap.style.display='';
map = new VEMap('myMap');
map.LoadMap(LA, 1, VEMapStyle.Road, false, VEMapMode.Mode2D, true, 1);
}
</script>
can any one help me?
Thanks
Knowing IE Mobile, I'd say it's something to do with your JavaScript probably.
How are you showing the map? Posting some code to your question would certainly help people narrow down the issue.
Looking at the directions service from bing.com on IE mobile, the map is a static image with the directions rendered on top - is this what you're doing? Or are you trying to call the default js map controls?
Edit to respond to update:
If you take a look at bing mobile you'll see that they aren't using the fully featured client side API, but are doing the bulk of the lifting on the server, culminating in a simple img tag being sent to the mobile browser to generate a static image request.
This sort of process is also talked about in this article on "Getting a map with the Virtual Earth Web Service", which concludes:
VEWS provides static images (on the fly), so you can insert them anywhere that support HTTP requests - mobile devices, JavaScript disabled browsers - or insert them into other documents such as PDFs.

Resources