Google Maps API V3 and stringByEvaluatingJavaScriptFromString?
Posted
by Joseph
on Stack Overflow
See other posts from Stack Overflow
or by Joseph
Published on 2010-06-16T18:28:24Z
Indexed on
2010/06/16
18:32 UTC
Read the original article
Hit count: 461
Hi,
I'm writing up an iPhone app using the Google Maps API V3, and I was wondering if it is still possible the use the stringByEvaluatingJavaScriptFromString function in the (void)webViewDidFinishLoad:(UIWebView *)webView
function?
A simple example being changing the map type (Assuming basic map setup):
- (void)webViewDidFinishLoad:(UIWebView *)webView{
[webView stringByEvaluatingJavaScriptFromString:@"map.setMapTypeId(google.maps.MapTypeId.SATELLITE);"];}
This was very possible the the 2.0 API, but I can't seem to get it right in the 3.0 API. Any insight would be much appreciated.
© Stack Overflow or respective owner