[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#1032166: timeline data not shown in browser (from local install)



Hello, I have done some tests and I think that the issue is related to CORS policy of the browsers.

If I install debian-timeline and I do:
chromium --allow-file-access-from-files file:///usr/share/debian-timeline/index.html &

I cannot see the events, but if I press F12 I can see them. So I think it's because 62-63 lines in media/debian-timeline.js:

Timeline.loadXML("xml/events.xml?" + random, function(xml, url) { events.loadXML(xml, url); }); Timeline.loadXML("xml/releases.xml?" + random, function(xml, url) { releases.loadXML(xml, url); }); Timeline.loadXML("xml/release_eras.xml?" + random, function(xml, url) { release_eras.loadXML(xml, url); });

result in trying to load the data with the file:/// scheme, and thus, blocked by the browser. I think this does not happen in https://timeline.debian.net because there is a web server serving the files, so no file:/// is used.

I'll try to see if there is other way to load the data so a browser is happy with a local install; I'll also investigate if this issue is also related to the problems declaring the DOCTYPE as html5 (bug #1032293: when we set DOCTYPE html, the data is not rendered either and the timeline appears as empty).

Kind regards
--
Laura Arjona Reina
https://wiki.debian.org/LauraArjona


Reply to: