/********************************************************************************/
/*                                                                              */
/*  Copyright (c) 2005-2006 by Totalidea Software GmbH                          */
/*	If you want to use this code, you must ask for permission!                  */
/*  Otherwise you are NOT allowed to use any part of this code                  */
/*                                                                              */
/********************************************************************************/

function VerCheck1()
{

		if (document.myform.valam16.value!="0")
		if (document.myform.valam17.value!="0")
		{alert( "Please note that premium and ultimate orders cannot be combined. They must be ordered separately!" );}
		document.myform.valam17.value="0";
}

function VerCheck4()
{

		if (document.myform.valam17.value!="0") 
		if (document.myform.valam16.value!="0")
		{alert( "Please note that premium and ultimate orders cannot be combined. They must be ordered separately!" );}
		document.myform.valam16.value="0";

}

function check()
{
	var amount1, amount4, amount5, amount6, amount7, hiddendata1, hiddendata4, hiddendata5, hiddendata6, hiddendata7, secorder
	
		//TWEAK-7
	if (document.myform.valam7_1.value>'0')
	{
	hiddendata7 = "&HADD[300304183][ADDITIONAL2]=" + document.myform.hiddenSubID.value;
	amount7='&PRODUCT[300304183]=' + (parseInt(document.myform.valam7_1.value)) + hiddendata7; 
	}
	else
	{
	amount7='&PRODUCT[300304183]=' + (parseInt(document.myform.valam7_1.value)); 
	}
	
	
	//TWEAK-XP
	if (document.myform.valam.value>'0')
	{
	hiddendata1 = "&HADD[300282871][ADDITIONAL2]=" + document.myform.hiddenSubID.value;
	amount1='PRODUCT[300282871]=' + (parseInt(document.myform.valam.value)) + hiddendata1;
	}
	else
	{
	amount1='PRODUCT[300282871]=' + (parseInt(document.myform.valam.value)) ;
	}
	
	//OUTLOOKBACKUPPRO
	if (document.myform.valam6.value>'0')
	{
	hiddendata4 = "&HADD[300282856][ADDITIONAL2]=" + document.myform.hiddenSubID.value;
	amount4='&PRODUCT[300282856]=' + (parseInt(document.myform.valam6.value)) + hiddendata4;
	}
	else
	{
	amount4='&PRODUCT[300282856]=' + (parseInt(document.myform.valam6.value));
	}
	
	//TWEAKVI ULTIMATE
	if (document.myform.valam17.value>'0')
	{
	hiddendata5 = "&HADD[300282606][ADDITIONAL2]=" + document.myform.hiddenSubID.value;
	amount5='&PRODUCT[300282606]=' + (parseInt(document.myform.valam17.value)) + hiddendata5; 
	}
	else
	{
	amount5='&PRODUCT[300282606]=' + (parseInt(document.myform.valam17.value)); 
	}
	
	//TWEAKVI PREMIUM
	if (document.myform.valam16.value>'0')
	{
	hiddendata6 = "&HADD[300282860][ADDITIONAL2]=" + document.myform.hiddenSubID.value;
	amount6='&PRODUCT[300282860]=' + (parseInt(document.myform.valam16.value)) + hiddendata6;
	}
	else
	{
	amount6='&PRODUCT[300282860]=' + (parseInt(document.myform.valam16.value)); 
	}
	
	{
		if (document.myform.opt1.checked==true)
		secorder='&PRODUCT[300282667]=1';
	}

	{
		if (document.myform.opt2.checked==true)
		secorder='&PRODUCT[300282668]=1';
	}

	{
		if (document.myform.opt1.checked==false && document.myform.opt2.checked==false)
		secorder='';
	}

	if (isNaN(document.myform.valam.value)) {
		alert( "Please enter numeric values only." );
		document.myform.valam.focus();
		return false;
	}

	if (isNaN(document.myform.valam6.value)) {
		alert( "Please enter numeric values only." );
		document.myform.valam6.focus();
		return false;
	}

	if (isNaN(document.myform.valam16.value)) {
		alert( "Please enter numeric values only." );
		document.myform.valam16.focus();
		return false;
	}

	if (isNaN(document.myform.valam17.value)) {
		alert( "Please enter numeric values only." );
		document.myform.valam17.focus();
		return false;
	}
		
		if (isNaN(document.myform.valam7_1.value)) {
		alert( "Please enter numeric values only." );
		document.myform.valam7_1.focus();
		return false;
	}
	
	{
		if (document.myform.valam.value<='0' || document.myform.valam.value=='')
		if (document.myform.valam6.value<='0' || document.myform.valam6.value=='')
		if (document.myform.valam16.value<='0' || document.myform.valam16.value=='')
		if (document.myform.valam17.value<='0' || document.myform.valam17.value=='')
		if (document.myform.valam7_1.value<='0' || document.myform.valam7_1.value=='')
		
		{
			secorder='0';
			alert ('Please select at least one product for purchase!');
			return false;
		}
	}
			if (secorder!='0')
			{
			location.href='https://secure.shareit.com/shareit/checkout.html?' + amount1 + amount4 + amount5 + amount6 + amount7 + secorder + '&COUPON1=' + document.myform.DiscCode.value + '&affiliate=' + document.myform.AffiliateID.value + '&backlink=http%3A%2F%2Fwww.totalidea.com%2Forders.php';
			}
}

function chkbox()
{
	{
		if (document.myform.opt1.checked==false)
		alert ('To protect your investment against accidental dataloss, this option should remain ticked. We cannot re-issue lost registration data for free without this service!');
	}
	if (document.myform.opt2.checked==true)
	document.myform.opt2.checked=false;
}

function chkbox1()
{
	{
		if (document.myform.opt2.checked==false)
		alert ('To protect your investment against accidental dataloss, this option should remain ticked. We cannot re-issue lost registration data for free without this service!');
	}
	if (document.myform.opt1.checked==true)
	document.myform.opt1.checked=false;
}