Reputation: 1
There are some issues with different KML files which most of my KML files can not be oppened in Openlayers but I can open them through the other tools.
I will appreciate if you check attached example and let me know what is the issue.
I'm trying to load (Drag and Drop) in this page: http://openlayers.org/en/v3.14.2/examples/drag-and-drop.html
Please find KML file code as here:
<?xml version="1.0" encoding="UTF-8"?>
<kml xmlns="http://www.opengis.net/kml/2.2" xmlns:gx="http://www.google.com/kml/ext/2.2" xmlns:kml="http://www.opengis.net/kml/2.2" xmlns:atom="http://www.w3.org/2005/Atom">
<Document xmlns=""><Style id="normalPlacemark"><IconStyle><color>ffbfbf40</color><scale>0.5</scale><Icon><href>http://kml-icons.actix.com/Dot.png</href></Icon></IconStyle></Style><Placemark><description>MS1</description><styleUrl>normalPlacemark</styleUrl><Point><coordinates>51.430944,35.713122</coordinates></Point></Placemark></Document></kml>
Upvotes: 0
Views: 183
Reputation: 3224
That KML file seems to be invalid. Whereas it may work with other tools, OpenLayers will not render the KML file if there are errors in it.
You can check for errors in the KML file using Google's KML validator.
Upvotes: 1