Here's the whole HTML for the form:
<html>
<head>
<title>Untitled Document</title>
</head>
<body bgcolor="#FFFFFF" text="#000000">
<b>NAMLLU Credit Bank Loan Application</b>
<form method=get action="loan.php">
First Name:
<input name="firstName" type="text">
<br>
Last Name:
<input name="lastName" type="text">
<br>
Age:
<input name="age" type="text" size=3>
<br>
Address:
<br>
<textarea name="address" rows=4 cols=40>
</textarea>
<p>
What is your current salary?:
<select name="salary">
<option value=0>Under $10,000</option>
<option value=10000>$10,000 - $25,000</option>
<option value=25000>$25,000 - $50,000</option>
<option value=50000>Over $50,000</option>
</select>
<p>
How much do you want to borrow?:
<br>
<input name="loan" type="radio" value=1000>Our $1,000 package at 8.0% interest
<br>
<input name="loan" type="radio" value=5000>Our $5,000 package at 11.5% interest
<br>
<input name="loan" type="radio" value=10000>Our $10,000 package at 15.0% interest
<p>
<input type=Submit value="Click here to Submit application">
<input type=reset value="Reset application form">
</form>
</body>
</html>
Here's the whole PHP page:
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<b>NAMLLU Credit Bank Loan Application Form</b>
<p>
<?
$salaryAllowance = $salary/5;
$ageAllowance = ($age/10 - ($age%10)/10)-1;
$loanAllowance = $salaryAllowance * $ageAllowance;
echo "Loan wanted:$loan<br>";
echo "Loan amount we will allow:$loanAllowance<p>";
if ($loan <= $loanAllowance) echo "Yes, $firstName $lastName, we are delighted to accept your application";
if ($loan > $loanAllowance) echo "Sorry, $firstName $lastName, we cannot accept your application at this time";
?>
</body>
</html>
Here's what gets output to the browser:
NAMLLU Credit Bank Loan Application Form
Loan wanted:
Loan amount we will allow:0
Yes, , we are delighted to accept your application