	//- Cookie Requirement Check -//
	document.cookie = 'Test';
	if ((document.cookie == '') && (String(window.location).indexOf('BrowserRequirement') < 0)) {
		window.location = '/Policy-BrowserRequirement/Index.htm';
	}

	//- Console_AddRemove -//
	function Console_AddRemove(oFromSet, oToSet, bIsAll) {
		//+ unselect
		for (var hOption = 0; hOption < oToSet.length; hOption++) {
			oToSet.options[hOption].selected = false;
		}
		//+ move
		for (hOption = oFromSet.length; hOption != 0; hOption--) {
			if ((bIsAll == true) || (oFromSet.options[hOption - 1].selected == true)) {
				oToSet.options[oToSet.length] = new Option(oFromSet.options[hOption - 1].text, oFromSet.options[hOption - 1].value, false, true);
				oFromSet.options[hOption - 1] = null;
			}
		}
	}
	//- Console_Pack -//
	function Console_Pack(oSet, oField) {
		var cPack = '';
		for (var hOption = 0; hOption < oSet.length; hOption++) {
			cPack += ',' + oSet.options[hOption].value;
		}
		oField.value = cPack.substring(1);
	}

	//- DecodeZip -//
	function DecodeZip(xZip) {
		var cZip = xZip.replace(/\?/g, '');
		return cZip;
	}

	//- DecodeFon -//
	function DecodeFon(xFon) {
		var cFon = '';
		if (xFon.length >= 10) {
			cFon = xFon.substr(0, 3) + '-' + xFon.substr(3, 3) + '-' + xFon.substr(6, 4)
			if ((xFon.length == 15) && (xFon.substr(10, 5) != '?????')) {
				cFon += ' x' + xFon.substr(10, 5).replace(/\?/g, '');
			}
		}	
		return cFon;
	}

	//- ToggleImage -//
	function SetImage(oImage, cImage) {
		oImage.src = cImage;
	}

//- String -//
	//- Right -//
	function Right(cStream, nLength) {
		if (nLength > cStream.length) {
			return '';
		} else {
			return cStream.substr(cStream.length - nLength, nLength);
		}
	}


	function openWindow(url) {
		popupWin = window.open(url,'openWin',"width=400,height=250,scrollbars=yes,resizable=yes");
	}

	function checkEnter(oForm, cAction, e){
		var characterCode;
		if (e && e.which) {
			e = e;
			characterCode = e.which;
		} else {
			e = event;
			characterCode = e.keyCode;
		}	 
		if(characterCode == 13){
			oForm.Action.value = cAction;
			oForm.submit();
			return false;
		}
		return true;
	}

   function OpenFax(oForm) {
		if (oForm.BillingCardType
		      && (oForm.BillingCardType.value == ""
				|| oForm.BillingCardNumber.value == ""
				|| oForm.BillingCardCVV.value == ""
				|| oForm.BillingCardExpire_Month.value == "?"
				|| oForm.BillingCardExpire_Year.value == "?")) {
			alert("Please fill in credit card information.");
		} else {
			var cAction, cTarget
			cAction = oForm.action;
			cTarget = oForm.target;
			
			oForm.action = "/Cart/Fax.asp";
			oForm.target = "_blank";
			oForm.submit();
			
			oForm.action = cAction;
			oForm.target = cTarget;
		}
		return true;
   }

	//- SelectOption -//
	function SelectOption(oSelect, cValue) {
		if ((oSelect == null) || (oSelect.options == null)) {
			return;
		}
	   for(hOption = 0; hOption < oSelect.options.length; hOption++) {
			if (oSelect.options[hOption].value == cValue) {
				oSelect.options[hOption].selected = true;
				return;
			}
	   }
	   oSelect.selectedIndex = 0;
	}
	
	//- SelectRadio -//
	function SelectRadio(oRadio, cValue) {
		for (nKey = 0; nKey < oRadio.length; nKey++) {
			if (oRadio[nKey].value == cValue) {
				if (oRadio[nKey].checked == false) {
					oRadio[nKey].checked = true;
				}
			} else if (oRadio[nKey].checked == true) {
				oRadio[nKey].checked == false;
			}
		}
	}

	function SubmitAction(oForm, cAction) {
		oForm.Action.value = cAction;
		oForm.submit();
	}

	function UncheckById(cId) {
		var oElement = document.getElementById(cId);
		if (oElement && oElement.type == "checkbox") {
			oElement.checked = false;
		}
	}

   //- PrintThis -//
	function PrintThis() {
		var ua = navigator.userAgent.toLowerCase();
		var is_mac = ua.indexOf('mac') > 0;
		if (is_mac) { alert('To print:\n\nUse Command + P. on your keyboard\n') }
		else { print(); } 
	}
