function InitLink ()
{
var Intro = false;
if (typeof (xtop.total) == 'undefined')
    if (typeof (xtop.Intro) == 'undefined')
        return
    else
        Intro = true;

if (!Intro && xtop.total.root == 'undefined')
    {
//    alert ('noch zu früh');
    setTimeout ('InitLink ()', 2000);
    return;
    }

if (Link_onLoad != null)
    Link_onLoad ();


var vorbestimmt = typeof (ExternEinrueckung) != 'undefined';
var Einrueckung = (!vorbestimmt) ? 188 : ExternEinrueckung;
var noIE = (typeof (innerWidth) == 'number');

if (xtop.total && !vorbestimmt)
    {
    if (xtop.total.Navi)
        if (noIE)
            Einrueckung = xtop.total.Navi.innerWidth
        else
            if (xtop.total.Navi.document)
                if (xtop.total.Navi.document.body)
                    Einrueckung = xtop.total.Navi.document.body.offsetWidth;
    }

if (!vorbestimmt)
    if ((noIE) ? (xtop.innerWidth < screen.width - 4) : (xtop.document.body.offsetWidth < screen.width - 4))
        Einrueckung += 6;

Einrueckung = ':' + Einrueckung;

with (document)
    for (var i = 0; i < links.length; i++) 
        if (links [i].className == 'x' || links [i].className == 'y')
            {
            if (links [i].parentNode.nodeName == 'LI' && links [i].parentNode.childNodes [0] == links [i])
                links [i].parentNode.type = 'square';

            links [i].target = '_blank';
            var save = links [i].firstChild.data;
            var Extra = (links [i].className == 'y') ? ':2:Wetterwerte' : '';

            links [i].href = ((Intro) ? '../' : xtop.total.root) + 'link.htm?' + links [i].href.slice (7) + Einrueckung + Extra;
            links [i].firstChild.data = save;
            }
        else
            {
            if (links [i].parentNode.nodeName == 'LI' && links [i].parentNode.childNodes [0] == links [i])
                 links [i].parentNode.type = 'circle';
            }

}





var Link_onLoad = window.onload;
window.onload = InitLink;
