Closed GoogleCodeExporter closed 9 years ago
Original comment by geocodezip
on 21 Dec 2011 at 12:55
There may be an issue with your fix:
per:
http://www.w3schools.com/jsref/jsref_unshift.asp
The unshift() method is supported in all major browsers, except Internet
Explorer.
Although it does seem to "work" in IE8, so perhaps that is no longer true.
MSDN says this:
http://msdn.microsoft.com/en-us/library/ezk94dwt(v=vs.94).aspx
Supported in the following document modes: Quirks, Internet Explorer 6
standards, Internet Explorer 7 standards, Internet Explorer 8 standards,
Internet Explorer 9 standards.
and
http://freewebdesigntutorials.com/javaScriptTutorials/jsArrayObject/unshiftMetho
d.htm
says it does work in IE
and stackoverflow agrees:
http://stackoverflow.com/questions/2197425/javascript-arrays
W3CSchools is really outdated, the unshift method is part of the ECMAScript 3rd
Edition standard which was approved and published as of December 1999.
There is no reason to avoid it nowadays, it is supported from IE 5.5 up.
Considering it, seems like it should be OK. I'll look at pulling in your fix.
Original comment by geocodezip
on 21 Dec 2011 at 1:28
Looking at the code, the doc order is being specifically reversed. I don't
know why. It does seem that the order in parser.docs should be that of the
provided array.
Original comment by geocodezip
on 21 Dec 2011 at 2:28
Thanks for accepting my report. I used unshift because it was the quickest
change. I know that W3Schools is definitely not the best reference, but it is
sometimes hard to avoid their SEO. As fir the code, if using push is preferred
(and it is what is used everywhere else), then changing the loop to count from
0 to less than internals.docset.length will work, and probably better.
Original comment by fami...@gmail.com
on 21 Dec 2011 at 2:37
fixed in revision 64
test case:
http://www.geocodezip.com/geoxml3_test/v3_geoxml3_test_arrayorderB.html
Original comment by geocodezip
on 26 Dec 2011 at 8:33
Does anyone know if I call parse(singleURL) repeatedly will the docs order
respect the order that parse was called?
Original comment by fitzy...@gmail.com
on 18 Sep 2014 at 8:54
Original issue reported on code.google.com by
fami...@gmail.com
on 20 Dec 2011 at 2:55Attachments: