]> git.pld-linux.org Git - projects/pld-builder.new.git/blob - script.js
move queue.html styles and script to standalone files
[projects/pld-builder.new.git] / script.js
1
2 // update date stamps to reflect viewers timezone
3 function update_tz(t) {
4         var el, off, dt,
5                 collection = document.getElementsByTagName('span');
6         for (off in collection) {
7                 el = collection[off];
8                 if (el.id == 'tz') {
9                         dt = new Date(el.innerHTML).toString();
10                         // strip timezone name, it is usually wrong when not initialized
11                         // from TZ env, but reverse calculated from os data
12                         dt = dt.replace(/\s+\(.+\)/, "");
13                         // strip "GMT"
14                         dt = dt.replace(/GMT/, "");
15                         el.innerHTML = dt;
16                 }
17         }
18 }
19
20 window.onload = update_tz;
This page took 0.097278 seconds and 3 git commands to generate.