	/************************************************************************************************************
	(C) www.dhtmlgoodies.com, October 2005
	
	This is a script from www.dhtmlgoodies.com. You will find this and a lot of other scripts at our website.	
	
	Terms of use:
	You are free to use this script as long as the copyright message is kept intact. However, you may not
	redistribute, sell or repost it without our permission.
	
	Thank you!
	
	www.dhtmlgoodies.com
	Alf Magne Kalleland
	
	************************************************************************************************************/	
	var textPadding = 3; // Padding at the left of tab text - bigger value gives you wider tabs
	var strictDocType = true;	// Set to true if you're using a strict or loose doctype, false otherwise
	
	/* Don't change anything below here */
	var tabObj;
	var activeTabIndex = -1;
	var MSIE = navigator.userAgent.indexOf('MSIE')>=0?true:false;
	var navigatorVersion = navigator.appVersion.replace(/.*?MSIE (\d\.\d).*/g,'$1')/1;
		

function toggleLayer(whichLayer,whichprice,lotsize)
{

if (document.getElementById)
{
// this is the way the standards work
var style2 = document.getElementById(whichLayer).style;
style2.display = "block";
qty1 = eval(document.forms['orderform'].ChampagneQty.value);
qty2 = eval(document.forms['orderform'].WhiteQty.value);
qty3 = eval(document.forms['orderform'].RedQty.value);
qty4 = eval(document.forms['orderform'].PortQty.value);
var totalqty = qty1 + qty2 + qty3 + qty4;

var totalcost = totalqty * eval(whichprice) * eval(lotsize);
var totalcostrounded = totalcost.toFixed(2)
document.getElementById("totalcost").innerHTML = totalcostrounded;
}

else if (document.all)
{
// this is the way old msie versions work
var style2 = document.all[whichLayer].style;
style2.display = "block";
//document.getElementById("purchasesize").innerHTML ="size text";
document.getElementById("totalcost").innerHTML = totalcost;
}
else if (document.layers)
{
// this is the way nn4 works
var style2 = document.layers[whichLayer].style;
style2.display = "block";
//document.getElementById("purchasesize").innerHTML ="size text";
document.getElementById("totalcost").innerHTML = totalcost;
}
}

