window.onload = function()
{
	initOrderButton();
}


function initOrderButton()
{
	var loBtn = document.getElementById("cmd_OrderNow");
	if(loBtn != null)
	{
		loBtn.onclick = function()
		{
			this.value= "Order wordt verwerkt...";
			this.onclick = function()
			{
				return false;
			}
		}
	}
}


function pop(url, width, height)
{
	window.open(url,'','width='+width+', height='+height+', menubar=no, status=no, location=no, toolbar=no, scrollbars=no, resizable=no', false);
}


function poppage(url, width, height)
{
	window.open(url,'','width='+width+', height='+height+', menubar=no, status=no, location=no, toolbar=no, scrollbars=yes, resizable=yes', false);
}


function showWebgroups(cFilter, cCluster)
{
	if(window.location.href.toLowerCase().indexOf("default.asp?") > 1)
	{
		var cHref = window.location.href;
		cHref = cHref.replace(/webgroupfilter\=[0-9,-]+\&?/gi,"");
		cHref = cHref.replace(/artdetail\=[^\&]+\&?/gi, "");
		cHref = cHref.replace(/clusterfilter\=[^\&]+\&?/gi, "");
		cHref = cHref.replace("?","?alstart=&webgroupfilter="+cFilter+"&");
		window.location.href = cHref;
	}
	else
	{
		window.location.href = "/default.asp?alstart=0&webgroupfilter="+cFilter;
	}
}


function fShowClusters(tcWebgroupfilter,tcClusterfilter)
{
	if(typeof tcWebgroupfilter == undefined)
		return;
	if(typeof tcClusterfilter == undefined)
		return;

	var lcHref = '/default.asp?pageid=85&docid=177';
	lcHref += '&webgroupfilter='+tcWebgroupfilter;
	lcHref += '&clusterfilter='+tcClusterfilter;

	window.location.href = lcHref;
}
