
/* javascript, 2004 orange8 interactive ag */

var hTimOut;
var shDivs = new Array();
var infoDivName;

function regDiv(name)
{
	shDivs.push(name);
}

function showDiv(name)
{
	hideAllDivs();
	window.clearTimeout(hTimOut);
	hTimOut = window.setTimeout('hideAllDivs()', 3000);
	if(document.getElementById(name))
		document.getElementById(name).style.visibility = 'visible';
}

function activateDiv(name)
{
	showDiv(name);
	try
	{
		//flashProxy.call('jumpTo', name);
	}
	catch (e)
	{ 
		//
	}
}

function hideDiv(name)
{
	if(document.getElementById(name))
		document.getElementById(name).style.visibility = 'hidden';	
}

function deactivateDiv(name)
{
	try
	{
		//flashProxy.call('jumpTo', 'reverse');
	}
	catch (e)
	{ 
		//
	}
	hideDiv(name);
}

function hideAllDivs()
{
	for(i=0; i<=shDivs.length-1; i++)
	{
		var name = shDivs[i];
		if(document.getElementById(name))
			document.getElementById(name).style.visibility = 'hidden';
	}
}

function showBlock(name)
{
	if(document.getElementById(name))
		document.getElementById(name).style.display = 'block';
}

function hideBlock(name)
{
	if(document.getElementById(name))
		document.getElementById(name).style.display = 'none';
}

function handleThumbs(nameToShow,nameToHide)
{
	if(document.getElementById(nameToShow))
		document.getElementById(nameToShow).style.display = 'block';
	if(document.getElementById(nameToHide))
		document.getElementById(nameToHide).style.display = 'none';
}

function roll_over(img_name, img_src) {
	document.getElementById(img_name).src = img_src;
}

function changebg(id, bg)
{
	document.getElementById(id).style.backgroundColor = bg;
}

function changefontcolor(id, fontcolor)
{
	document.getElementById(id).style.color = fontcolor;
}

function setTextDecoration(id, option)
{
	document.getElementById(id).style.textDecoration = option;
}

function changeBgImg(id, bgImg)
{
	document.getElementById(id).style.backgroundImage = "url(/images/layout/leftnav/"+bgImg+")";
	document.getElementById(id).style.backgroundRepeat = "no-repeat";
	document.getElementById(id).style.backgroundPosition = "top left";
}

function openPopup(url, width, height)
{
	openWnd(url, 'o8sppopup', 'scrollbars=yes,status=no,toolbar=no,location=no,directories=no,resizeable=no,menubar=no,width='+width+',height='+height);
}

function openWnd(url, windowname, attribute)
{
	if(windowname=='')
		windowname='o8sppopup';
	wnd = window.open(url,windowname,attribute);
	wnd.focus(); 
}

function ShowCableCompany(name)
{
	if(document.getElementById('protectmap'))
		document.getElementById('protectmap').style.visibility = 'visible';
	if(document.getElementById(name))
		document.getElementById(name).style.visibility = 'visible';
	infoDivName = name;
}

function HideCableCompany()
{
	if(document.getElementById('protectmap'))
		document.getElementById('protectmap').style.visibility = 'hidden';
	if(document.getElementById(infoDivName ))
		document.getElementById(infoDivName ).style.visibility = 'hidden';
}

function launchPartnerProgram(intPartnerID, intAboID)
{
	var features = "height=700,width=800,alwaysLowered=0,alwaysRaised=0,channelmode=0,dependent=1,directories=0,fullscreen=0,hotkeys=1,location=0,menubar=0,resizable=0,scrollbars=1,status=0,titlebar=1,toolbar=0,z-lock=0";
	//var x = 'https://my.quickline.com/webanmeldung/webanmeldung_step1.aspx';
	var x = 'https://order.quickline.com';
	var remote = open(x, "PartnerProgram", features, "PartnerProgram");
}

function submitOfferLocator(btnId,e)
{
    var keycode;
    if (window.event)
        keycode = window.event.keyCode;
    else
        if (e)
            keycode = e.which;
        else
            return true;

    if (keycode == 13)
    {
        WebForm_DoPostBackWithOptions(new WebForm_PostBackOptions(btnId, "", true, "", "", false, true));
        return false;
    }
    else
       return true;
}