modaresimr / earth-api-samples

Automatically exported from code.google.com/p/earth-api-samples
1 stars 0 forks source link

fetchKml() doesn't obey HTTP cache headers #72

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Load a randomized KML (i.e. PHP generated) using fetchKml()
2. Load the same exact URL again using fetchKml(). Observe: the first KML
file contents are being used instead of the second--implies caching
3. Start -> Run "taskkill /f /im geplugin.exe" to kill GE plugin instances
4. Refresh the page
5. Reload the randomized KML using fetchKml() Observe: the first KML file
contents aren't being used anymore--implies cache was destroyed

Cache-control, Expire, etc. headers are ignored

What is the expected output or behavior? What do you see instead?
fetchKml() should respect HTTP headers requiring it not to cache KML

What version of the plug-in are you using? On what operating system? In
which browser?
4.3.x
Windows XP + Vista
FF2+,IE6+

Please provide any additional information (code snippets/links) below.

Original issue reported on code.google.com by api.roman.public@gmail.com on 12 Sep 2008 at 8:18

GoogleCodeExporter commented 8 years ago
A really helpful resolution of this issue would be for the plugin to replace 
the 
features and placemarks from the first kml with those in the file loaded from 
the 
second request.  It would be nice to be able to toggle a user alert on reload 
of the 
modified kml.  Very useful in a dynamic update situation, and would save a lot 
of 
client-side code.  In other words, it would be nice if the pugin mimiced the 
behavior of Google Earth Desktop by asking (or not if user input toggled off) 
if the 
plugin should replace the old features with the new ones from a file with the 
same 
name/url.

Original comment by scottbro...@gmail.com on 13 Sep 2008 at 9:40

GoogleCodeExporter commented 8 years ago
Issue 122 has been merged into this issue.

Original comment by api.roman.public@gmail.com on 16 Dec 2008 at 1:28

GoogleCodeExporter commented 8 years ago
Issue 18 has been merged into this issue.

Original comment by api.roman.public@gmail.com on 5 Feb 2009 at 8:29

GoogleCodeExporter commented 8 years ago
This was actually fixed with the Google Earth Plugin 5.0 release.

There are still cases where this can occur on Windows, specifically when 
Internet 
Explorer 6 is installed (there seems to be a bug in WinINet before IE7 related 
to 
disregarded Cache-control headers).

Setting Cache-control and Expires headers should resolve the problem in all 
cases.

Original comment by api.roman.public@gmail.com on 14 May 2009 at 6:13

GoogleCodeExporter commented 8 years ago
Hi, the KML is still getting stuck in my cache with the following software and 
plugin:

Plugin version: 5.1.7938.4346
Operating system: Windows Vista
Browsers: IE7, FF3.5, Chrome 4.0.249.89

It's making testing very difficult - could there be a parameter in fetchKml to 
override caching?

Original comment by horuskol...@gmail.com on 15 Feb 2010 at 4:53

GoogleCodeExporter commented 8 years ago
The problem, fetching a latest dynamic kml with the same name over time, is 
still and
NOT fixed yet!!!  Neither FF 3.6 nor IE 8.0.7600.16385 works.

Original comment by janmo...@gmail.com on 20 Feb 2010 at 3:29

GoogleCodeExporter commented 8 years ago
hey 
I have the same problem though loading different kml file every time ??
fetch kml is called wiht the second url but shows the data for the first one 
though 
deleting the old one

thanks

Original comment by eng.heba...@gmail.com on 14 May 2010 at 8:47

GoogleCodeExporter commented 8 years ago
I also have this problem- I'm writing a a program that refreshes the kml with 
ajax in a set interval (fast, like every 5 seconds)- the server is constantly 
getting new data and is creating new kml files that need to be grabbed, but 
fetchKML refuses to do the job, and I think it's because of caching. Using a 
NetworkLink has no issues- but I need to be able to change the view in the 
plugin and get data from the ExtendedData section of the kml- therefore I need 
to use fetchKML!

Original comment by bbengf...@gmail.com on 17 Jun 2010 at 4:36