|
/* Copyright Jürgen Reule 2012-2023 */ |
|
|
|
|
|
|
function error() { |
|
|
|
return true; |
|
|
} |
|
|
function sterne() { |
|
|
|
|
|
|
|
d = new Date(); |
|
|
|
tag = d.getDate(); // 1-31 |
|
|
|
monat = d.getMonth()+1; // 1-12 |
|
|
|
min = d.getMinutes(); // 0-59 |
|
|
|
sec = d.getSeconds(); // 0-59 |
|
|
|
|
|
|
|
mt = monat*100 + tag; |
|
|
|
|
|
|
|
window.setTimeout('sterne()', (60-sec)*1000); |
|
|
|
|
|
|
|
if ((mt >= 925 && mt < 1201 // Blätter |
|
|
|
|| mt >= 1216 || mt < 501) // Schnee |
|
|
|
|
|
|
|
&& (min >= 27 && min < 33 |
|
|
|
|| min >= 57 || min < 3)) |
|
|
|
|
|
|
|
background(sterne2); |
|
|
|
else background(''); |
|
|
} |
|
|
function background(bg) { |
|
|
|
|
|
|
|
if (document.body.background != '' |
|
|
|
&& document.body.background != sterne2) return; |
|
|
|
|
|
|
|
if (document.body.background != bg) |
|
|
|
document.body.background = bg; |
|
|
|
|
|
|
|
if (parent.frames) { |
|
|
|
f = parent.frames; |
|
|
|
|
|
|
|
for (i=0; i<f.length; i++) { |
|
|
|
|
|
|
|
if (f[i].document |
|
|
|
&& f[i].document.body) { |
|
|
|
p = f[i].document.body; |
|
|
|
l = document.body; |
|
|
|
|
|
|
|
if (p.background != l.background) |
|
|
|
p.background = l.background; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
} |
|
|
window.onerror = error; |
|
|
|
|
|
|
if (document.getElementById) { |
|
|
|
|
|
|
|
if (document.getElementById |
|
|
|
&& document.getElementById('sterne') |
|
|
|
&& document.getElementById('sterne').src) |
|
|
scriptsrc = document.getElementById('sterne').src; |
|
|
|
|
|
|
|
if (document.getElementById |
|
|
|
&& document.getElementById('stars') |
|
|
|
&& document.getElementById('stars').src) |
|
|
scriptsrc = document.getElementById('stars').src; |
|
|
|
|
|
|
|
scriptname = scriptsrc.substring(0, |
|
|
|
scriptsrc.lastIndexOf('.js')); |
|
|
|
|
|
|
|
wayback = scriptname.indexOf('js_'); if (wayback >= 0) |
|
|
|
scriptname = scriptname.substring(0,wayback) + 'im_' + |
|
|
|
scriptname.substring(3+wayback); |
|
|
|
|
|
|
|
if (scriptname) { |
|
|
|
|
|
|
|
sterne2 = scriptname + '.gif'; |
|
|
|
|
|
|
|
if (document.images) { |
|
|
|
|
|
|
|
sterne3 = new Image(); |
|
|
|
sterne3.src = sterne2; |
|
|
|
} |
|
|
|
sterne(); |
|
|
|
} |
|
|
} |
|