function getquote(tab, id, chkbox)
{
	if (tab == 'banner')
	{
		var ordertotal=document.form1.ordertotal.value;
		if (chkbox=="animate")
		{
			if (document.getElementById("animated"+id).checked==true)
			{
				document.getElementById("price"+id).checked=true;
				document.getElementById("flash"+id).checked=false;
			}
		}
		if (chkbox=="flash")
		{
			if (document.getElementById("flash"+id).checked==true)
			{
				document.getElementById("price"+id).checked=true;
				document.getElementById("animated"+id).checked=false;
			}
		}
		if (chkbox=="price")
		{
			if (document.getElementById("price"+id).checked==false)
			{
				document.getElementById("animated"+id).checked=false;
				document.getElementById("flash"+id).checked=false;
			}
		}
	
		packno=document.form1.packno.value;
		p=1;
		actualtotal=0;
		expresstotal=0;

		while (p <= packno)
		{
			packtotal=0;
			express=0;

			if (document.getElementById("price"+p).checked==true)
			{
				packtotal=packtotal+parseInt(document.getElementById("price"+p).value);

				if (document.getElementById("psdfile").checked==true)
				{
					packtotal=packtotal+parseInt(document.getElementById("psdfile").value);
				}
				if (document.getElementById("animated"+p).checked==true)
				{
					packtotal=packtotal+parseInt(document.getElementById("animated"+p).value);
				}
				if (document.getElementById("flash"+p).checked==true)
				{
					packtotal=packtotal+parseInt(document.getElementById("flash"+p).value);
				}
				express=express+(parseInt(document.getElementById("express"+p).value));		
			}
			expresstotal=expresstotal+express;
			actualtotal=actualtotal+packtotal;
			p=p+1;
		}
		ibno=document.form1.customno.value;
		ib=1;
		aibtotal=0;
		ibexpresstotal=0;

		while (ib <= ibno)
		{
			ibtotal=0;
			ibexpress=0;

			if (document.getElementById("customprice"+ib).checked == true)
			{
				ibtotal=ibtotal+parseInt(document.getElementById("customprice"+ib).value);
				if (document.getElementById("psdfile").checked==true)
				{
					ibtotal=ibtotal+parseInt(document.getElementById("psdfile").value);
				}
				if (document.getElementById("customanimated"+ib).checked==true)
				{
					ibtotal=ibtotal+parseInt(document.getElementById("customanimated"+ib).value);
				}
				if (document.getElementById("customflash"+ib).checked==true)
				{
					ibtotal=ibtotal+parseInt(document.getElementById("customflash"+ib).value);
				}
				ibexpress=ibexpress+(parseInt(document.getElementById("customexpress"+ib).value));
			}
			ibexpresstotal=ibexpresstotal+ibexpress;
			aibtotal=aibtotal+ibtotal;
			ib=ib+1;
		}
	
		actualtotal=actualtotal+aibtotal;
		actualtotal2=actualtotal;
		actualtotal=actualtotal+parseInt(ordertotal);
	
		if (actualtotal2==0)
		{
			document.form1.express.checked=false;
		}
	
		if (document.form1.express.checked==true)
		{
			actualtotal=actualtotal+expresstotal+ibexpresstotal;
		}
		document.form1.totalsum.value=actualtotal;
		document.getElementById("bannertotal").innerHTML="<b>$"+actualtotal+".00</b>";	
	}
	else
	if(tab == 'logos')
	{
		var ordertotal=document.form2.ordertotal.value;
		packno=document.form2.packno.value;
		L=1;
		if (id > 0)
		{
			while (L <= packno)
			{
				if (L!=parseInt(id))
				{
					document.getElementById("logoprice"+L).checked=false;
				}
				L++;
			}
		}
		p=1;
		actualtotal=0;
		expresstotal=0;

		while (p <= packno)
		{
			packtotal=0;
			express=0;
			if (document.getElementById("logoprice"+p).checked==true)
			{
				packtotal=packtotal+parseInt(document.getElementById("logoprice"+p).value);
				express=express+(parseInt(document.getElementById("logoexpress"+p).value));
			}
			expresstotal=expresstotal+express;
			actualtotal=actualtotal+packtotal;
			actualtotal2=actualtotal;
			p=p+1;
		}
		actualtotal=actualtotal+parseInt(ordertotal);

		if (actualtotal2==0)
		{
			document.form2.express.checked=false;
		}
	
		if (document.form2.express.checked==true)
		{
			actualtotal=actualtotal+expresstotal;
		}

		document.form2.totalsum.value=actualtotal;
		document.getElementById("logototal").innerHTML="<b>$"+actualtotal+".00</b>";
	}
	else
	if(tab == 'psd2')
	{
		var ordertotal=document.form4.ordertotal.value;
		packno=document.form4.packno.value;
		L=1;
		if (id > 0)
		{
			while (L <= packno)
			{
				if (L!=parseInt(id))
				{
					document.getElementById("psd2price"+L).checked=false;
				}
				L++;
			}
		}
		p=1;
		actualtotal=0;
		expresstotal=0;

		while (p <= packno)
		{
			packtotal=0;
			express=0;
			if (document.getElementById("psd2price"+p).checked==true)
			{
				packtotal=packtotal+parseInt(document.getElementById("psd2price"+p).value);
				express=express+(parseInt(document.getElementById("psd2express"+p).value));
			}
			expresstotal=expresstotal+express;
			actualtotal=actualtotal+packtotal;
			actualtotal2=actualtotal;
			p=p+1;
		}
		actualtotal=actualtotal+parseInt(ordertotal);

		if (actualtotal2==0)
		{
			document.form4.express.checked=false;
		}
	
		if (document.form4.express.checked==true)
		{
			actualtotal=actualtotal+expresstotal;
		}

		document.form4.totalsum.value=actualtotal;
		document.getElementById("psd2total").innerHTML="<b>$"+actualtotal+".00</b>";
	}
	else
	if (tab == 'landing')
	{
		var ordertotal=document.form3.ordertotal.value;

		packno=document.form3.packno.value;
		L=1;

		if (id > 0)
		{
			while (L <= packno)
			{
				if (L!=parseInt(id))
				{
					document.getElementById("landingprice"+L).checked=false;
				}
				L++;
			}
		}
		p=1;
		actualtotal=0;
		expresstotal=0;
		htmltotal=0;

		while (p <= packno)
		{
			packtotal=0;
			express1=0;
			landhtml=0;
			if (document.getElementById("landingprice"+p).checked==true)
			{
				packtotal=packtotal+parseInt(document.getElementById("landingprice"+p).value);
				express1=express1+(parseInt(document.getElementById("landingexpress"+p).value));
				landhtml=landhtml+(parseInt(document.getElementById("html"+p).value));				
			}
			expresstotal=expresstotal+express1;
			htmltotal=htmltotal+landhtml;
			actualtotal=actualtotal+packtotal;
			actualtotal2=actualtotal;
			p=p+1;
		}
		actualtotal=actualtotal+parseInt(ordertotal);

		if (actualtotal2==0)
		{
			document.form3.express.checked=false;
			document.form3.htmlfile.checked=false;
		}

		if (document.form3.express.checked==true && document.form3.htmlfile.checked==false)
		{
			actualtotal=actualtotal+expresstotal;
		}

		if (document.form3.htmlfile.checked==true && document.form3.express.checked==false)
		{
			actualtotal=actualtotal+htmltotal;
		}

		if (document.form3.express.checked==true && document.form3.htmlfile.checked==true)
		{
			actualtotal=actualtotal+expresstotal+htmltotal;
		}

		document.form3.totalsum.value=actualtotal;
		document.getElementById("landingtotal").innerHTML="<b>$"+actualtotal+".00</b>";
	}
}

function extraclose(counter)
{
	document.getElementById(counter).style.display="none";
	extragetquote(counter,'price');
}

function extragetquote(id,chkbox)
{
	var ordertotal=document.form1.ordertotal.value;
	//alert(id);alert(chkbox);
	if (chkbox=="animate")
	{
		if (document.getElementById("customanimated"+id).checked==true)
  		{
		document.getElementById("customprice"+id).checked=true;
		document.getElementById("customflash"+id).checked=false;
		}
	}
	if (chkbox=="flash")
	{
		if (document.getElementById("customflash"+id).checked==true)
	  	{
		document.getElementById("customprice"+id).checked=true;
		document.getElementById("customanimated"+id).checked=false;
		}
	}
	if (chkbox=="price")
	{
		if (document.getElementById("customprice"+id).checked==true)
	  	{
		document.getElementById("customanimated"+id).checked=true;
		}
		if (document.getElementById("customprice"+id).checked==false)
	  	{
		document.getElementById("customanimated"+id).checked=false;
		document.getElementById("customflash"+id).checked=false;
		}
	}
	
	packno=document.form1.packno.value;
	p=1;
	actualtotal=0;
	expresstotal=0;
	while (p <= packno)
	{
		packtotal=0;
		express=0;
		if (document.getElementById("price"+p).checked==true)
		{
			packtotal=packtotal+parseInt(document.getElementById("price"+p).value);
			if (document.getElementById("psdfile").checked==true)
			{
			packtotal=packtotal+parseInt(document.getElementById("psdfile").value);
			}
			if (document.getElementById("animated"+p).checked==true)
			{
			packtotal=packtotal+parseInt(document.getElementById("animated"+p).value);
			}
			if (document.getElementById("flash"+p).checked==true)
			{
			packtotal=packtotal+parseInt(document.getElementById("flash"+p).value);
			}
			express=express+(parseInt(document.getElementById("express"+p).value));
		}
	expresstotal=expresstotal+express;
	actualtotal=actualtotal+packtotal;
	p=p+1;
	}
	//---------------------------
	ibno=document.form1.customno.value;
	//alert(ibno);
	ib=1;
	aibtotal=0;
	ibexpresstotal=0;
	//ibexpress=0;
	while (ib <= ibno)
	{
		ibtotal=0;
		ibexpress=0;
		if (document.getElementById(ib).style.display!="none")
		{
		if (document.getElementById("customprice"+ib))
		{
		if (document.getElementById("customprice"+ib).checked == true)
		{
			ibtotal=ibtotal+parseInt(document.getElementById("customprice"+ib).value);
			if (document.getElementById("psdfile").checked==true)
			{
			ibtotal=ibtotal+parseInt(document.getElementById("psdfile").value);
			}
			if (document.getElementById("customanimated"+ib).checked==true)
			{
			ibtotal=ibtotal+parseInt(document.getElementById("customanimated"+ib).value);
			}
			if (document.getElementById("customflash"+ib).checked==true)
			{
			ibtotal=ibtotal+parseInt(document.getElementById("customflash"+ib).value);
			}
			ibexpress=ibexpress+parseInt(document.getElementById("customexpress"+ib).value);
			//alert(document.getElementById("customexpress"+ib).value);
			//alert(ibexpress);
		}
		}
		}
	ibexpresstotal=ibexpresstotal+ibexpress;
	//alert(ibexpresstotal);
	aibtotal=aibtotal+ibtotal;
	ib=ib+1;
	}
	
	actualtotal=actualtotal+aibtotal;
	actualtotal2=actualtotal;
	actualtotal=actualtotal+parseInt(ordertotal);
	
	if (actualtotal2==0)
	{
		document.form1.express.checked=false;
	}
	
	if (document.form1.express.checked==true)
	{
	actualtotal=actualtotal+expresstotal+ibexpresstotal;
	}
	//alert(actualtotal);
	document.form1.totalsum.value=actualtotal;
	document.getElementById("bannertotal").innerHTML="<b>$"+actualtotal+".00</b>";	
}

