<!--

/* reset forms to their original values
*/

function resetForms(){
	var i = 0;
	for (i=0; i < document.forms.length; i++) {
		document.forms[i].reset()
	}
	}

function checkLife(oForm){
//	alert ('Check Life')
    var sValue = oForm.Membership.options[oForm.Membership.selectedIndex].value
    var sText = oForm.Membership.options[oForm.Membership.selectedIndex].text

    if (sText == "Life")    {
		oForm.Type.options[oForm.Type.selectedIndex].value = 4;
		oForm.Type.options[oForm.Type.selectedIndex].text = 'Life'
		//		oForm.Type.select();
	}
//	else
//		oForm.submit();
  }
function checkPaidBy(oForm){
//	alert('checkPaidBy');
    var sValue = oForm.PaidBy.options[oForm.PaidBy.selectedIndex].value;
    var sText = oForm.PaidBy.options[oForm.PaidBy.selectedIndex].text;
	 	oForm.Currency.options[oForm.Currency.selectedIndex].value = 'GBP';
		oForm.Currency.options[oForm.Currency.selectedIndex].text = 'GBP';
		oForm.PaidBy.blur();

    if (sText == "Helen Turin" || sText == "PayPal USD")    {
		oForm.Currency.options[oForm.Currency.selectedIndex].value = 'USD';
		oForm.Currency.options[oForm.Currency.selectedIndex].text = 'USD';
	}	
		oForm.Amount.focus();
		oForm.Amount.select();
	/*
    if (sText == "PayPal GBP")    {
		oForm.Currency.options[oForm.Currency.selectedIndex].value = 0;
		oForm.Currency.options[oForm.Currency.selectedIndex].text = 'GBP';
	}
    if (sText == "PayPal USD")    {
		oForm.Currency.options[oForm.Currency.selectedIndex].value = 1;
		oForm.Currency.options[oForm.Currency.selectedIndex].text = 'USD';
	}/*
    if (sText == "Standing Order" || sText == "PayPal GBP" || sText == "PayPal GBP" )    {
		oForm.Currency.options[oForm.Currency.selectedIndex].value = 0;
		oForm.Currency.options[oForm.Currency.selectedIndex].text = 'GBP'; 
	}*/
  }

function checkSelect(oForm){
    var sValue = oForm.elements[0].options[oForm.elements[0].selectedIndex].value
    var sText = oForm.elements[0].options[oForm.elements[0].selectedIndex].text
 
    if (sValue == "")    
		oForm.reset()   
	else
		oForm.submit();
  }

function checknum(num){

num=(num.indexOf(".")>=0)?num.substring(0, num.indexOf(".")).replace(/\D/g,"")+"."+num.substring(num.indexOf(".")+1, num.length).replace(/\D/g,""):num.replace(/\D/g,"");

return num=(num=="")?0:num;

}

	
// -->

