How to share KML documents?

1,095 views
Skip to first unread message

ShaneB

unread,
Jul 26, 2008, 7:47:41 PM7/26/08
to KML Developer Support - Getting Started with KML
Hello. So I have created a KML file that has various information in
it. This KML file is updated about once every few days as my database
gets new information.

How can I allow others view the content without having to download the
KML file every time it is updated? Ideally, when they load up Google
Earth it should just grab the newest version of the KML file.

How can I set this up? Any help is appreciated.

jeaninemm

unread,
Jul 27, 2008, 9:23:28 AM7/27/08
to KML Developer Support - Getting Started with KML
These are the two things I've been doing. I would like comments.
1) I upload the kmz file to my own server and give people the link.
They have two options.
If they have Google Earth, they can click on the link and open it in
Google Earth. If they don't have Google Earth, they can put the link
in the location field of Google Maps.
2) I have joined Google Earth community and uploaded the file there.
I'm actually not sure I've done this correctly or adequately.

Comments?

Jeanine

The link is: http://newmedia.purchase.edu/~Jeanine/hudsontrail/hudsontrail.kmz

barryhunter [KML Guru]

unread,
Jul 27, 2008, 12:02:14 PM7/27/08
to KML Developer Support - Getting Started with KML
Luckily KML has the concept of network links to power this very
functionality!

http://code.google.com/apis/kml/documentation/kml_tut.html#network_links

Basically you create a small KML file that simply contains as Network
Link to a url where the GE client should get the data. Then every time
the user opens Google Earth it will fetch the latest data (you can
also specify an exact schedule.

ShaneB

unread,
Jul 27, 2008, 4:19:54 PM7/27/08
to KML Developer Support - Getting Started with KML
Hi barry,
Thanks for the advice, but it doesn't seem to be working. Try
taking this KML file
http://www.myirishpictures.com/power/LollandPower.kml

Which links to this KMZ file
http://www.myirishpictures.com/power/LollandPower.kmz

But when I load the KML file (which merely contains a link to the KMZ
file) nothing happens. The link is not successfully made. Any advice?

~Shane

barryhunter [KML Guru]

unread,
Jul 27, 2008, 6:19:57 PM7/27/08
to KML Developer Support - Getting Started with KML
Hmm, see
http://feedvalidator.org/check.cgi?url=http%3A%2F%2Fwww.myirishpictures.com%2Fpower%2FLollandPower.kml

but there also is some very suspicious html appended to the end that
almost certainly causes Google Earth to reject it.

See
http://code.google.com/apis/kml/documentation/kml_tut.html#kml_server
about the MIME type issue.

(the .kmz file suffers the same issues (and its not really a .kmz
anyway it looks more like kml) )

On Jul 27, 9:19 pm, ShaneB wrote:
> Hi barry,
> Thanks for the advice, but it doesn't seem to be working. Try
> taking this KML filehttp://www.myirishpictures.com/power/LollandPower.kml
>
> Which links to this KMZ filehttp://www.myirishpictures.com/power/LollandPower.kmz

ShaneB

unread,
Jul 27, 2008, 7:33:37 PM7/27/08
to KML Developer Support - Getting Started with KML
D'oh! You are absolutely right. I use a free hosting site to develop
these files (GoDaddy) and they append random HTML crap to the end of
all files. I am going to host these two files on a paid server so that
issue should go away. I will report back soon if any problems remain.
Thank you for your help!

~SHane


On Jul 27, 3:19 pm, barryhunter [KML Guru] wrote:
> Hmm, seehttp://feedvalidator.org/check.cgi?url=http%3A%2F%2Fwww.myirishpictur...
>
> but there also is some very suspicious html appended to the end that
> almost certainly causes Google Earth to reject it.
>
> Seehttp://code.google.com/apis/kml/documentation/kml_tut.html#kml_server

barryhunter [KML Guru]

unread,
Jul 27, 2008, 7:51:00 PM7/27/08
to KML Developer Support - Getting Started with KML
btw, if you havent seen it, pages.google.com offer free hosting for
KML files - and they dont mess with your files ;)
Reply all
Reply to author
Forward
0 new messages