


function bp_updatePrice(){
	var noOfHosts;
	var rad_val;
	var calculateCost;
	var savingsAnnualy;
	var ANNUAL_COST = 24;
	var MONTHLY_COST = 30;
	var TERM = 12;
	noOfHosts = document.MC.selectHosts.options.selectedIndex + 1;
	document.getElementById("hostNum").value = noOfHosts;
	
	for (var i=0; i < document.MC.plan.length; i++)
   		{
   			if (document.MC.plan[i].checked)
      			{
				rad_val = document.MC.plan[i].value;
				
     			}
   		}	
	
	if(rad_val){
	document.MC.mcPrice.value = rad_val;
	}
	
	calculateCost =  noOfHosts * rad_val;
	document.getElementById("costNoOfHosts").innerHTML = "&pound;"+calculateCost;	
	savingsAnnualy = noOfHosts *(MONTHLY_COST-ANNUAL_COST)* TERM;
	totalcost_annualplan = calculateCost * TERM;
	if(rad_val==ANNUAL_COST)
				{
				
					document.MC.mcmonthTerm.value = "12_months_term";
					document.getElementById("term").value=12;
					document.getElementById("annualcost_annualbox").innerHTML = "&pound;"+totalcost_annualplan;
					document.getElementById("savingPrice_annualbox").innerHTML = "&pound;"+savingsAnnualy;
					document.getElementById("prepaidcost_annual").innerHTML = "&pound;"+totalcost_annualplan;
					document.getElementById("monthly_price_annual").innerHTML = "&pound;"+ANNUAL_COST*noOfHosts;
					document.getElementById("bp_price_block_annual").style.display ="block";
					document.getElementById("bp_price_block_monthly").style.display ="none";
					
				}
				else
				{
					
					document.MC.mcmonthTerm.value = "1_month_term";
					document.getElementById("term").value=1;
					document.getElementById("total_cost").style.display = "none";
					document.getElementById("savingPrice").innerHTML = "&pound;"+savingsAnnualy;
					document.getElementById("bp_price_block_annual").style.display ="none";
					document.getElementById("bp_price_block_monthly").style.display ="block";
				}
	
if(rad_val==ANNUAL_COST )
{
	document.getElementById("mcproductId").value = 1001;	
}
else 
{
	document.getElementById("mcproductId").value = 1006;
}

	
/*if(rad_val==ANNUAL_COST && document.MC.audioCheck.checked == false)
{
	document.getElementById("mcproductId").value = 1003;	
}
else{
		if(rad_val==MONTHLY_COST && document.MC.audioCheck.checked == false)
		{
			document.getElementById("mcproductId").value = 1002;
		}
		else{
				if(rad_val==ANNUAL_COST && document.MC.audioCheck.checked == true)
				{
					document.getElementById("mcproductId").value = 1005;
				}
				else
				{
					document.getElementById("mcproductId").value = 1004;
				}
			}
	}*/
}


function displayWindow1(url, target, width, height, scrollbar){
window.open(url,target,'toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars='+scrollbar+',resizable=yes,width='+width+',height='+height);
}

	function buttonHi()
	{
		dom = document.getElementById("bp_buy_button");
		dom.style.backgroundPosition ="right"; 
	}
	function buttonLow()
	{
		document.getElementById("bp_buy_button").style.backgroundPosition ="left";
	}
	
	

