Open GoogleCodeExporter opened 8 years ago
Can you provide a link to your page that exhibits the problem? A copy of that
kmz file on my server works:
http://www.geocodezip.com/geoxml3_test/v3_geoxml3_kmztest_linkto.html?filename=s
ample_GMaps_slideshow_kmz.zip
Is your page on the domain: http://eastafricadreams.com?
geoxml3 is subject to the XmlHttpRequest same domain restriction.
Original comment by geocodezip
on 2 Sep 2012 at 6:39
[deleted comment]
Hi,
You may have answered the question. If I'm interpreting the answer
correctly.
The tests were run from the desktop but calling a KMZ in public space -
'sample_GMaps_slideshow.kmz'.
This was included in the response - how to reproduce the error =
myParser.parse('http://www.eastafricadreams.com/KMZ/sample_GMaps_slideshow.kmz')
;
Although the documents suggest I could run the tests from a local directory
without an on-line connection I couldn't get this to work with any KML or
KMZ file.
The KML file ran successfully by retaining the HTML and JS files on the
local machine and referring to the published KML on the public server -
'http://www.eastafricadreams.com/KMZ/'.
The same test failed when the link was changed to KMZ.
So it may be that I need to publish the test to the server and try again.
This will be a task for next weekend.
It doesn't explain though why I can't get a local copy of the files to work
at all. A quick test with both KML & KMZ versions gets an Access Denied
Error at line 1467 = ' xhrFetcher.fetcher.open('GET', url, true);' in
routine 'geoXML3.fetchXML = function (url, callback) {'.
Original comment by jbamja...@eastafricadreams.com
on 2 Sep 2012 at 7:15
What browser? Different browsers have different policies for local resources.
Original comment by geocodezip
on 2 Sep 2012 at 7:42
Hi,
The tests were conducted on IE8.
The following errors occurred with the listed browsers:
Opera V11.61
Invalid value for property: Background
Line 1 -moz-Linear-gradient (left,#000,#fff)
Firefox V3.6.3
log:Unable to retrieve sample_GMaps_slideshow.kmz: XML Parsing Error: not
well-formed
Location:
file:///H:/safari_files/Web_Pages/Test%20pages/sample_GMaps_slideshow.kmz
Line Number 1, Column 3:
Safari V4.0.4
The page didn't load. Being unfamiliar I can't locate an error with this
browser. It does have an option to report an error & the web page is
automatically filled - but this occurs on every page anyway.
Original comment by jbamja...@eastafricadreams.com
on 3 Sep 2012 at 6:26
IE8 is running into the XMLHttpRequest limitation on local files:
http://code.google.com/p/xmlhttprequest/issues/detail?id=23
What is the use case for geoxml3? Does it require KMZ and local files? If you
can use KML, does the poly branch work for you with KML?
Original comment by geocodezip
on 4 Sep 2012 at 2:17
Please explain "What is the use case for geoxml3?"
Extract of Html showing returned errors:
" myParser = new geoXML3.parser({
map: map,
processStyles: true,
createMarker: addMyMarker,
createOverlay: addMyOverlay
});
// myParser.parse('H:/safari_files/Web_Pages/Test
pages/sample_GMaps_slideshow.kml'); // Error=Invalid argument.
// myParser.parse("H:\\safari_files\\Web_Pages\\Test
pages\\sample_GMaps_slideshow.kmz"); // Error=Invalid argument.
// myParser.parse("H:\\safari_files\\Web_Pages\\Test
pages\\sample_GMaps_slideshow.kml"); // Error=Invalid argument.
// myParser.parse("sample_GMaps_slideshow2.kml"); // Error=Access is
denied
//
myParser.parse('http://www.eastafricadreams.com/KMZ/sample_GMaps_slideshow.kml')
;
// No error"
I cannot get local KML files to work. I've even overridden 'url' value in
'var xhrFetcher = new Object();' to no avail.
Does it require KMZ and local files?
I only need local file access to make debugging easier. I do need KMZ in the
final application. The purpose of usign KMZ is to reduce file sizes on the
server. I currently use multiple hard coded JS but this generates file sizes
in excess of 150k.
If you can use KML, does the poly branch work for you with KML?
Haven't tried this yet. I thought I'd keep the tests as simple as possible
to begin with, until I understand what geoXML3 is doing.
Note I have had to modify the 'description' with '(c)' as geoXML3 doesn't
like the '�' character. So I will have to amend my KML and re-publish to
test 'poly'.
Original comment by jbamja...@eastafricadreams.com
on 4 Sep 2012 at 5:52
Please explain "What is the use case for geoxml3?"
"Use case" is the way you are planning on using geoxml3 in your application.
If you _need_ KMZ, then it isn't worth testing the polys branch.
If you only need local file access for local testing, then the work around is
to test on a server; if you can run a webserver on your local machine that
might solve the problem as well.
From my (so far not very extensive) research, this is a security restriction on
XMLHttpRequest in at least IE8, probably in the others as well. You might also
be able to work around it by using the ActiveX version of XMLHttpRequest by
default rather than the native version, not sure I want to make that change to
the archive.
Original comment by geocodezip
on 4 Sep 2012 at 10:26
Original issue reported on code.google.com by
jbamja...@eastafricadreams.com
on 2 Sep 2012 at 5:39