2010-10-15 22 views

回答

0

這似乎是可能獲得緯度/經度對,大致指向國家的中心通過發送國家名稱的地理編碼。見例如到

http://maps.google.com/maps/geo?q=Spain&output=xml 

響應中的XML響應

<kml xmlns="http://earth.google.com/kml/2.0"><Response> 
    <name>Spain</name> 
    <Status> 
    <code>200</code> 
    <request>geocode</request> 
    </Status> 
    <Placemark id="p1"> 
    <address>Spain</address> 
    <AddressDetails Accuracy="1" xmlns="urn:oasis:names:tc:ciq:xsdschema:xAL:2.0"><Country><CountryNameCode>ES</CountryNameCode><CountryName>Espanya</CountryName></Country></AddressDetails> 
    <ExtendedData> 
     <LatLonBox north="45.2440000" south="35.1730000" east="5.0980000" west="-12.5240000" /> 
    </ExtendedData> 
    <Point><coordinates>-3.7492200,40.4636670,0</coordinates></Point> 
    </Placemark> 
</Response></kml> 
相關問題