		function application() {
		rcode="PHA";
		if (document.form1.select.value != ''){
			if (document.form1.select2.selectedIndex != -1){
		Amount = document.form1.select.value;
		ins = document.form1.ins.status;
		term = document.form1.select2.selectedIndex;
		myrate = document.form1.apprate.value;
		if (term == 0){
		var months=12
		}
		if (term == 1){
		var months=24
		}
		if (term == 2){
		var months=36
		}
		if (term == 3){
		var months=48
		}
		if (term == 4){
		var months=60
		}
		window.open('https://www.fundingcorp.co.uk/secureapplication/v3/?id=TheM0nEysd63hjdf893r&cw=1&MarketingResponse='+rcode+'&Amount='+Amount+'&ins='+ins+'&term='+months+'&apr='+myrate,'mywin','width=10,height=10');		
		
		}
			else
			alert('Please select a repayment');
			}
		else
		alert('Please select a loan amount');
		}