UIWebView에서 Google지도를 만들었으며 라우팅 물건과 함께 완벽하게 작동합니다. 하지만 지금은 WebView에 다른지도를로드하고 Google지도에서 가져 오는 모든 기능을 얻고 싶습니다. 내가 어떻게 해?iphone의 UIWebView에서 google지도처럼 anyother지도를 사용하는 방법?
예 : UIWebView에로드하려고합니다. http://stage.discoveritalia.it/conbipel/. 이것은 이탈리아지도입니다. 나는 Google지도가 아이폰 앱에서 작동하는 것과 같은 방식으로 사용하고 싶다. Plz 도와주세요.
Google지도의 경우이 http://code.google.com/apis/maps/documentation/examples/map-simple.htmlMIMEType을 html 파일로 저장하면됩니다. Then \t NSString * htmlPath = [[NSBundle mainBundle] pathForResource : @ "map"ofType : @ "html"]; \t NSData * htmlData = [NSData dataWithContentsOfFile : htmlPath]; \t [map loadData : htmlData MIMEType : @ "text/html"textEncodingName : @ "utf-8"baseURL : [NSURL URLWithString : @ "http://maps.google.com/"]]; 그 후에 자바 스크립트로 파싱하면 결과가 나옵니다. 내가 사용하는 html 파일을 변경해야한다고 생각합니다. 당신이 어떤 생각을 가지고 있다면, PLZ 도와주세요. – wolverine