if(window.name != "_P_O_P_U_P_" && window.name.substr(0, 4) != '_nf_')
{
    window.onerror=function(msg, URL, lineNum){return true;}
    var newLocation = self.location.href;
    if(newLocation.indexOf('?TEMPLATE_URL=') == -1)
    {
        if(self.location.href == top.location.href)
        {
            lcFrameRedirect(newLocation);
        }
    }
    else
    {
        newLocation = newLocation.substring(newLocation.indexOf('?TEMPLATE_URL=') + 14);
        if(self.location.href == top.location.href)
        {
            lcFrameRedirect(newLocation);
        }
    }
}

function lcFrameRedirect(strBaseUrl)
{
    if(typeof(bFramePageCheckProblemBrowser) != "undefined" &&
        typeof(bIFrameProblemBrowser) != "undefined")
    {
        if(bFramePageCheckProblemBrowser == true &&
            bIFrameProblemBrowser == true)
            {
                return;
            }
    }

    var sliceCount = 3;
    if(strBaseUrl.indexOf('/_lccms_/_') != -1)
    {
        strBaseUrl = strBaseUrl.slice(0, strBaseUrl.lastIndexOf('/_lccms_/_'));
    }
    else
    {
        strBaseUrl = strBaseUrl.slice(0, strBaseUrl.lastIndexOf('/'));
    }

    top.location.href = strBaseUrl + "?SHOW_URL=" + self.location.href;
}

// *** Öffnet einen Link in einem Fenster fixer Größe ***
function lcOpenWindow(strURL, iWidth, iHeight)
{
  lcOpenedWindow = window.open(strURL, "_nf_lcOpenedWindow", "width=" + iWidth + ",height=" + iHeight + ",left=100,top=200,scrollbars=yes,menubar=no,toolbar=no,status=no,location=no");
  lcOpenedWindow.focus();
}

// *** Fügt eine E-Mail-Adresse ein ***
function InsertMail(mailnam,mailsvr,maildom,text)
{
  if(text=="" || text == null || typeof(text) == "undefinded")
    document.write('<a href="mailto:'+mailnam+'@'+mailsvr+'.'+maildom+'">'+mailnam+'@'+mailsvr+'.'+maildom+'</a>');
  else
    document.write('<a href="mailto:'+mailnam+'@'+mailsvr+'.'+maildom+'">'+text+'</a>');
}

