kml

Load kml extendeddata into variable with Geoxml3

扶醉桌前 提交于 2019-11-28 12:59:53
I understand that Geoxml3 has a built in feature to load kml extendeddata into variables (from its source code - see bellow), but I couldn't find the way to access those variables after parsing. Does anyone know how to do it? Thanks, cheers. (line 544 of geoxml3.js of kmz branch): // add extended data to variables var extDataNodes = node.getElementsByTagName('ExtendedData'); if (!!extDataNodes && extDataNodes.length > 0) { var dataNodes = extDataNodes[0].getElementsByTagName('Data'); for (var d = 0; d < dataNodes.length; d++) { var dn = dataNodes[d]; var name = dn.getAttribute('name'); if (

KML opens with the wrong geoposition

和自甴很熟 提交于 2019-11-28 12:00:31
问题 I'm trying to create a map of the Stockholm's subway lines in Fusional Tables. In the Fusion Tables I created a map with geo each station: https://www.google.com/fusiontables/DataSource?docid=1K7F2DMY5JBA6ZQOH8a1a4dQjwxoksRDMJ3-wPEg#map:id=3 I want to connect them to the polyline. Options to create polylines and way in the tables there, or they are very well hidden. So I created this KML file and loaded into tables: <?xml version="1.0" encoding="UTF-8"?> <kml xmlns="http://www.opengis.net/kml

Can anyone guide me how to get Google Directions between two locations using JSON

混江龙づ霸主 提交于 2019-11-28 11:33:23
问题 I have heard that KML file is no longer available since 27 July 2012 (because Google has changed the structure of retrieving Google Directions, now you can only get it by JSON or XML) So plz guide me how to make road route between 2 location. BELOW CODE IS WORKING FINE NW ENJOY GUYS This is my code: I refered this link : http://www.androidhive.info/2012/08/android-working-with-google-places-and-maps-tutorial/ PlacesMapActivity.java In below code it is showing straight line between 2 point.

Specifying Lat & Long for Leaflet TileLayer

本秂侑毒 提交于 2019-11-28 02:25:59
Seems like a simple question, but I have been tearing my hair out for hours now. I have a series of files ie. kml_image_L1_0_0.jpg kml_image_L2_0_0.jpg kml_image_L2_0_1.jpg kml_image_L2_1_0.jpg kml_image_L2_1_1.jpg etc. However just plotting them on the leaflet map surface understandibly puts the images at 0,0 on the earths surface, and the 0 zoom level inferred by the files should really be about 15 or so. So I want to specify the latitude and longitude where the images should originate , and what zoom level they should start at. I have tried bounds (which doesn't display anything) and I have

Google Maps kml files

本秂侑毒 提交于 2019-11-28 02:20:57
问题 If I use an embeded google map in my website, will the data contained in an kml displayed be publicly viewable? Will it be possible for the user to access just the data displayed (i.e., not the user interface) or would I have to provide that separately? 回答1: If you load your KML through the API, with GGeoXml(), (V2), or KmlLayer(), (V3), then your data needs to be in a public server because it is parsed by Google's servers and they need to be able to get to it. If you load it with a third

Adding a KML layer to an Android maps application

≡放荡痞女 提交于 2019-11-28 01:40:58
问题 I have been starting out in the world of Android development recently and I am working on an application which shows a map using the Google API SDK, it is pretty much the original example but edited a little bit. It works a treat but I wish to do more with it. My question is: How do you add a KML layer to this? I've not found many examples out there and none of them are very clear. I know how to do this with Javascript on websites but not in android. Can anyone help? 回答1: Google added a

Java API for KML (JAK) embedding images in kmz files

十年热恋 提交于 2019-11-28 01:25:56
问题 Is there a way to just add an image file into a kmz file using Java API for KML (JAK)? I can create a kml file with no problem, but I'm trying to just embed a resources (such as an images folder with some image files), but the marshalAsKmz method takes only Kml objects as additional files, so I can't figure out how to just include extra images. 回答1: I've been using JAK for over a year on a project. I use it to create the KML, then I marshal it as just plain KML (not KMZ). I created a separate

Google Maps zoom gets overridden, when using a kml file

∥☆過路亽.° 提交于 2019-11-27 20:34:53
How do I specify zoom level for google maps in a kml file or why is it that my zoom level gets over ridden when I load this file. My question is actually how do I control zoom of a map for the following link: http://code.google.com/apis/maps/documentation/javascript/examples/layer-kml-features.html By default, the map is centered and zoomed to the bounding box of the contents of the kml layer. You can change the default behaviour with preserveViewport property of google.maps.KmlLayerOptions object. If you set it to true the map isn't centered and zoomed. In the example, use: var nyLayer = new

Google Maps API and KML File LocalHost Development Options

霸气de小男生 提交于 2019-11-27 18:12:41
The Google Maps JavaScript version 3 API library documentation clearly explains : The Google Maps API supports the KML and GeoRSS data formats for displaying geographic information. These data formats are displayed on a map using a KmlLayer object, whose constructor takes the URL of a publicly accessible KML or GeoRSS file. There are even several Stack Overflow questions about how to load local data: Loading a local .kml file using google maps? Google Maps kml files Some of the answers have pointed to third party libraries which can parse KML locally without the file needing to be public:

Loading a local .kml file using google maps?

谁说我不能喝 提交于 2019-11-27 17:26:33
I created a hello world program to load a local kml file (borrowed from google's docs): var ctaLayer = new google.maps.KmlLayer("http://localhost:8080/kml/cta.kml"); This does not work (nothing gets loaded). However, when I change that line to: var ctaLayer = new google.maps.KmlLayer("http://gmaps-samples.googlecode.com/svn/trunk/ggeoxml/cta.kml"); it loads properly. Both kml files are identical. What do I need to do to get it to load when serving it myself? (I tried both absolute and relative paths, and I know the paths I am using are correct...) Also I added the correct mime type to my