cannot visualize kml in web app

697
2
07-19-2017 01:52 AM
AnggaMarthafifsa
New Contributor

Hi,

I'm working with arcgis web app right now.

in that web app i want to visualize data from KML url, but unfortunately it failed.

the steps that i did is

1. I successfully created web map in arcgis online and add KML web map layer and save it as gsmap.

kml in web map

2. Then i go to the content and select gsmap and create a web app -> using template and created a new web app, but i cannot see the layer from KML

web app kml

i did quick investigation about the problem and found this problem, width of image source is 0 px.

image error width

if i remove the width or change the value upper than 0 it worked

change image width manual

Here is the kml file

<?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>
     <name>map_rain.kml</name>
     <Folder>
          <name>GSMaP Passage Data</name>
          <Folder>
               <name>map_rain</name>
               <Folder>
                    <name>Rain</name>
                    <Style>
                         <ListStyle>
                              <listItemType>checkHideChildren</listItemType>
                              <bgColor>00ffffff</bgColor>
                              <maxSnippetLines>2</maxSnippetLines>
                         </ListStyle>
                    </Style>
                    <GroundOverlay>
                         <Icon>
                              <href>map_rain.png</href>
                         </Icon>
                         <altitude>100000</altitude>
                         <altitudeMode>absolute</altitudeMode>
                         <LatLonBox>
                              <north>60</north>
                              <south>-60</south>
                              <east>200</east>
                              <west>-160</west>
                         </LatLonBox>
                    </GroundOverlay>
                    
               </Folder>
               
          </Folder>
     </Folder>
</Document>
</kml>
‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍

and this is the image

image kml

Really appreciate of your help.

Tags (1)
0 Kudos
2 Replies
KellyHutchins
Esri Frequent Contributor

Is your web map public? I created a test app using a kml file and was able to view it in both the Online Map Viewer and one of the configurable apps: 

http://www.arcgis.com/apps/SimpleViewer/index.html?appid=27df731b59754646884fcf75ad7e04e9 

0 Kudos
AnggaMarthafifsa
New Contributor

Thank you Kelly for the reply

Here is the link of my web app

http://gicait.maps.arcgis.com/apps/SimpleViewer/index.html?appid=6a42be2d99324f96a6d312e58ebbdc71 

Can you try it with my kml code and also my image which cover all the world (https://community.esri.com/servlet/JiveServlet/showImage/2-701483-363367/map_rain.png) i faced the problem with this case, but it worked perfect in arcgis online and google earth.

Many thanks.

0 Kudos