SpOnENV_SERVER_IMG = 'http://www.spiegel.de';
SpOnENV_SERVER = 'http://www.spiegel.de';
SpOnENV_VideoPopupParams  = 'width=630,height=490,scrollbars=auto,resizable=yes,screenX=150,screenY=100';
SpOnENV_AudioPopupParams  = 'width=600,height=427,scrollbars=auto,resizable,screenX=150,screenY=100';
SpOnENV_FlashPopupParams  = 'scrollbars=no,screenX=150,screenY=100';
SpOnENV_PdfPopupParams    = 'width=600,height=550,scrollbars=no,screenX=150,screenY=100,resizable';
SpOnENV_PopTopPopupParams = 'width=500,height=310,resizable,screenX=150,screenY=100,status=no';
SpOnENV_BigaPopupParams_0   = 'width=625,height=545,scrollbars=auto,resizable,screenX=150,screenY=10';
SpOnENV_BigaPopupParams_1   = 'width=625,height=650,scrollbars=auto,resizable,screenX=150,screenY=10';
SpOnENV_BigaPopupParams_2   = 'width=780,height=650,scrollbars=auto,resizable,screenX=10,screenY=10';
SpOnENV_BigaPopupParams_3   = '';
SpOnENV_BigaPopupParams   = 'width=625,height=545,scrollbars=auto,resizable,screenX=150,screenY=10';
function goURL(frmlrname){
adresse = document.forms[frmlrname].to.options[document.forms[frmlrname].to.selectedIndex].value;
if(adresse=="") adresse = "javascript:void(0)";
if(adresse.substr(0,1) == '/') adresse = SpOnENV_SERVER + adresse;
window.location = adresse;
}
function RandomImg (Pfad,aBilder,Ext){
if (typeof(Ext)=='undefined')Ext = "";
if (Pfad =="img"){
Pfad = SpOnENV_SERVER_IMG + "/img/0,1020,";
if(Ext!="") Ext = ",00" + Ext;
} else {
Pfad = SpOnENV_SERVER_IMG + "/static/img/" + Pfad;
}
return Pfad + aBilder[Math.round(Math.random()*(aBilder.length-1))] + Ext;
}
function spon_popup(seite,breite,hoehe,scroll,rsize) {
sbars = (scroll==1)? "yes" : "no";
rsize = (rsize==1)? "yes" : "no";
if(seite.substr(0,1) == '/') seite = SpOnENV_SERVER + seite;
var win_name = breite+hoehe;
var win_attr = "menubar=no,location=no,directories=no,toolbar=no,screenX=0,screenY=0";
win_attr += ",width=" + breite + ",height=" + hoehe + ",scrollbars=" + sbars + ",resizable=" + rsize;
sponWin = open(seite,win_name,win_attr);
sponWin.focus();
}	
function bilderladen(pfad,bildIds,ext) {
if(document.images) {
if(pfad.indexOf("img")==1) {
pfad = pfad + '0,1020,';
ext = ',00' + ext;
}
if(pfad.substr(0,1) == '/') pfad = SpOnENV_SERVER_IMG + pfad;
var bilder = new Array();
for(i=0;i < bildIds.length;i++) {
bilder[i] = pfad + bildIds[i] + ext;
}
chgImg = new Array();
for(i=0;i < bilder.length;i++) {
chgImg[i] = new Image();
chgImg[i].src = bilder[i];
}
}
}
function bildtausch(imgname,imgnr) {
if(document.images) {
if(imgnr < (chgImg.length)) imgname.src = chgImg[imgnr].src;
}
}
if(document.images) {
navpic = new Array();
navpic[0] = new Image();
navpic[0].src = SpOnENV_SERVER_IMG + '/static/sys/navpic_lo.gif';
navpic[1] = new Image();
navpic[1].src = SpOnENV_SERVER_IMG + '/static/sys/navpic_hi.gif';
}
function nav_hilo(num,imgname) {
if(document.images) {
imgname.src = navpic[num].src;
}
}
function showReiter(name,id) {
for (i=1;i<=10;i++){
var name2 = name + i;
if (document.getElementById(name2)) {
if (id == i) {
document.getElementById(name2).style.background = '#ffffff';
} else {
document.getElementById(name2).style.background = '#f0f0f0';
}
}
}
}
aNav = [];
aNav[0]=['HOME','http://www.spiegel.de/','','Home'];
aNav[1]=['POLITIK','http://www.spiegel.de/politik/','','Politik'];
aNav[2]=['WIRTSCHAFT','http://www.spiegel.de/wirtschaft/','','Wirtschaft'];
aNav[3]=['PANORAMA','http://www.spiegel.de/panorama/','','Panorama'];
aNav[4]=['SPORT','http://www.spiegel.de/sport/','','Sport'];
aNav[5]=['KULTUR','http://www.spiegel.de/kultur/','','Kultur'];
aNav[6]=['NETZWELT','http://www.spiegel.de/netzwelt/','','Netzwelt'];
aNav[7]=['WISSENSCHAFT','http://www.spiegel.de/wissenschaft/','','Wissenschaft'];
aNav[8]=['UNISPIEGEL','http://www.spiegel.de/unispiegel/','','UniSPIEGEL'];
aNav[9]=['REISE','http://www.spiegel.de/reise/','','Reise'];
aNav[10]=['AUTO','http://www.spiegel.de/auto/','','Auto'];
aNav[11]=['DER SPIEGEL','http://www.spiegel.de/spiegel/','','DER SPIEGEL'];
aNav[12]=['ENGLISH SITE','http://www.spiegel.de/international/','','English Site'];
aNav[13]='';
aNav[14]=['SCHLAGZEILEN','http://www.spiegel.de/schlagzeilen/','','Schlagzeilen'];
aNav[15]=['WETTER','http://wetter.spiegel.de/spiegel/','','Wetter'];
aNav[16]=['FORUM','http://forum.spiegel.de/','','Forum'];
aNav[17]=['ARCHIV','http://www.spiegel.de/archiv/','','Archiv'];
aNav[18]=['DOSSIERS','http://www.spiegel.de/archiv/dossiers/','','Dossiers'];
aNav[19]=['LÄNDERLEXIKON','http://www.spiegel.de/jahrbuch/','','Länderlexikon'];
aNav[20]=['NEWSLETTER','http://www.spiegel.de/dertag/','','Newsletter'];
aNav[21]=['SHOP','http://www.spiegel.de/shop/','','Shop'];
aNav[22]=['ABO','http://www.spiegel.de/abo/','','Abo'];
function InhaltNavigation(){
var NavInhalt;
var ColChannel = document.getElementById('sponkopf').getAttribute('bgcolor');
NavInhalt = '<table id="tsponmenue" width="154" bgcolor="'+ColChannel+'" cellpadding="0" cellspacing="0" border="0">';
for(i in aNav) {
if(aNav[i]!=""){ 
NavInhalt += '<tr><td><a href="' + aNav[i][1] + '" title="' + aNav[i][3] + '"' + aNav[i][2] + ' class="sponnav" onmouseover="hili('+i+')" onmouseout="hili('+i+')"><img id="iNavPfeil'+i+'" style="visibility:hidden;" src="' + SpOnENV_SERVER_IMG + '/static/img/einzelpfeil_weiss_7x7.gif" width="7" height="7" hspace="2" border="0" alt="&gt;">&nbsp;' +aNav[i][0]+ '<\/a><\/td><\/tr>';
} else if(aNav[i]==""){
NavInhalt += '<tr><td height="18" class="sponnav"><br><\/td><\/tr>';
}
if(i!=aNav.length-1) NavInhalt += '<tr><td height="1" width="154" style="background: url(' + SpOnENV_SERVER_IMG + '/static/popups/strichel-3x1-666666.gif) repeat-x;"><spacer type="block" width="1" height="1"><\/td><\/tr>';
}
NavInhalt += '<\/table>';
document.getElementById('dsponmenue').innerHTML=NavInhalt;
}
// ######## POSITIONIERUNG ########
function PositionNavigation(){
var PosX, PosY
var NS6 = (navigator.appName.indexOf("Netscape") != -1 && document.getElementById && navigator.userAgent.indexOf("rv:0")!=-1) ? 1 : 0;
if (document.getElementById && !NS6) {
PosX = document.getElementById('sponkopf').offsetLeft + document.getElementById('sponmenue').offsetLeft;
PosY = document.getElementById('sponkopf').offsetTop + document.getElementById('sponmenue').offsetTop + document.getElementById('isponmenue').offsetHeight;
}
if (NS6) {
PosX = document.getElementById('isponmenue').offsetLeft;
PosY = document.getElementById('isponmenue').offsetTop + document.getElementById('isponmenue').offsetHeight;
}
document.getElementById('dsponmenue').style.left = PosX;  
document.getElementById('dsponmenue').style.top = PosY;
}
// ############ ZEIGEN - VERBERGEN ###############
var NavHide=0;
function ShowHideNavi(status) {
if(status==0){
document.getElementById('dsponmenue').style.visibility = 'hidden';
hili(SponChannel);
} else {
document.getElementById('dsponmenue').style.visibility = 'visible';
}
if (NavHide) clearTimeout(NavHide);
NavHide=setTimeout("aus()",500);
}
function aus() {
if(!NavOn) ShowHideNavi(0);
}
// ######### HIGHLIGHTING ##########
function hili(id){
with(document){
if (getElementById('iNavPfeil'+id)) getElementById('iNavPfeil'+id).style.visibility= (document.getElementById('iNavPfeil'+id).style.visibility=="visible")? "hidden" : "visible";
if (getElementById('iNavPfeil'+SponChannel)) getElementById('iNavPfeil'+SponChannel).style.visibility = (NavOn)? "visible" : "hidden";
}
}
// ######## NAVIGATION AUFRUFEN ##############
function SetNavi() {
InhaltNavigation();
PositionNavigation();
ShowHideNavi(0);
ShowHideNavi(1);
NavOn=1;
hili(SponChannel);
}
// ######## MAUSBEWEGUNG KONTROLLIEREN #########
document.onmouseover=OnSponNav;
var NavOn;
function OnSponNav(el) {
if (document.all) {
var thisEl = event.srcElement;
}
if (document.getElementById && !document.all) {
var thisEl = el.target
}
if (thisEl!=-1) {
var i = 0;
var DomPath="";
DomPathArray = [];
var node = thisEl;
while(node.tagName!="HTML") {
if(node.tagName!="undefined") {
DomPathArray[i] = node.id;
DomPath += DomPathArray[i]+'/';
i++;
}
node = node.parentNode;
}
if ( (DomPath.match("dsponmenue")) || (DomPath.match("isponmenue")) ) NavOn = 1;	
if ( ( !DomPath.match("dsponmenue") && !DomPath.match("isponmenue") ) && NavOn) {NavOn = 0; ShowHideNavi(1);}
}
}
// ########### PULL-DOWN-ALTERNATIVE #############
function SponNavAlt(){
document.write('<table width="153" cellpadding="0" cellspacing="0" border="0"><tr><td>');
document.write('<select name="to" width="131">');
document.write('<option value="" selected="selected">Ressort wählen<\/option>');
document.write('<option value="">----------------<\/option>');
document.write('<option value="/">Home<\/option>');
document.write('<option value="/politik/">Politik<\/option>');
document.write('<option value="/wirtschaft/">Wirtschaft<\/option>');
document.write('<option value="/panorama/">Panorama<\/option>');
document.write('<option value="/sport/">Sport<\/option>');
document.write('<option value="/kultur/">Kultur<\/option>');
document.write('<option value="/netzwelt/">Netzwelt<\/option>');
document.write('<option value="/wissenschaft/">Wissenschaft<\/option>');
document.write('<option value="/unispiegel/">UniSPIEGEL<\/option>');
document.write('<option value="/reise/">Reise<\/option>');
document.write('<option value="/auto/">Auto<\/option>');
document.write('<option value="/spiegel/">DER SPIEGEL<\/option>');
document.write('<option value="/international/">English Site<\/option>');
document.write('<option value="">----------------<\/option>');
document.write('<option value="/schlagzeilen/">Schlagzeilen<\/option>');
document.write('<option value="http://wetter.spiegel.de/spiegel/">Wetter<\/option>');
document.write('<option value="http://forum.spiegel.de/">Forum<\/option>');
document.write('<option value="/archiv/">Archiv<\/option>');
document.write('<option value="/archiv/dossiers/">Dossiers<\/option>');
document.write('<option value="/jahrbuch/">Länderlexikon<\/option>');
document.write('<option value="/dertag/">Newsletter<\/option>');
document.write('<option value="/shop/">Shop<\/option>');
document.write('<option value="/abo/">Abo<\/option>');
document.write('<option value="">----------------<\/option>');
document.write('<option value="/sptv/">Spiegel TV<\/option>');
document.write('<option value="/kulturspiegel/">KulturSPIEGEL<\/option>');
document.write('<option value="/leserbriefe/">Leserbriefe<\/option>');
document.write('<option value="/marktplatz/">Marktplatz<\/option>');
document.write('<\/select><\/td>');
document.write('<td><input type="image" src="/static/sys/submitpfeil-20x22.gif" name="los" align="right" border="0">');
document.write('<\/td><\/tr><\/table>');
return false;
}

