tags:

views:

80

answers:

1

I am attempting to create an application that will allow a small group of users to subscribe" to a KML feed we produce. The users want to view the KML using Google Earth on their mobile devices which does not support "network links" (please add this...).

The KML contains several hundred different place marks with related information as wells about 30-40 polygons. I am using the HTTP protocol. So far, I can successfully perform the ClientLogin and get the authorization token, I can retrieve a list of user maps and find the one I am supposed to update. Now I'm stuck. Every single feature needs to be updated every time...I don't want to have to manually update every feature or delete each one and re-add. What I would really like is to just provide a KML document and tell it to just replace ALL content in this map with this KML.....is this possible?

Summary:

  • Login, then...
  • Find a map with a specific name, then...
  • Replace that maps content with a KML file

I thought of just deleting the map and creating a new one with the same name, but that might mess up the UI of the mobile device and force the user to have to re-select the map every time I update them (every day). This is not completely out of the question, but it's certainly not ideal.

What is the best way to handle this?

A: 

Good question. I don't think the HTTP protocol allows for this in the way you suggested (login, find map, replace entire map with KML).

The delete and recreate method that you suggested in your comment might work, but you'll have to wait until issue 2590 is fixed to resolve the 400 BAD REQUEST problem. The workaround that Google suggest for this issue is to upload individual KML features as required, which really won't help you as that's exactly what you're trying to avoid!

See my answer on this similar question for more details.

Day