create a form with gross pay-tax amount-net pay

Project Description:

create a form that collects number of hours worked, and hourly pay rate. an income tax rate of 10% is assumed. then, it calculates and displays the gross pay, tax amount, and net pay.  gross pay: hours multiplied by pay rate  tax amount: gross pay multiplied by tax rate in decimal format (use .10 instead of 10%)  net pay: tax amount subtracted from gross pay shown below, is an example of how the form should look like. you worked 10 hours, and you make 10 dollars per hour. you enter those inputs. then you click on the button which displays the gross pay amount (10*10 = 100), tax amount (100*.10 = 10), and net pay (100-10 = 90).

this is what it is supposed to look like.

i attached the file.




this is what i have so far. i can't get the gross pay amount, tax amount, and net pay to work when i hit the calculate button.


<html>
<head><title> stephanie york</title>

</head>
<body>
<form>

enter working hours: <input type="text" name="working hours" size="10"> <br/><br/>
enter pay rate: <input type="text" name="pay rate" size="10"> <br/><br/>
gross pay: <input type="text" name="gross pay" size="10"> <br/><br/>
tax amount: <input type="text" name="tax amount" size="10"> <br/><br/>
net pay: <input type="text" name="net pay" size="10" readonly> <br/><br/>
<input type="button" value="calculate" onclick='
var wh = document.forms (0).working hours.value;
var pr = document.forms (0).pay rate.value;
var gp = working hours*pay rate;
var tax amount = gross pay*.10;
var np = gross pay-tax amount;
document.forms(0).net.pay = np;
'>

</form>
</body>
</html>

i need help by 6:00 tonight. thanks, connie
Skills Required:
Project Stats: Edited

Price Type: Fixed

Project Budget: $10 to $20
Expired
Total Proposals: 0
1 Current viewersl
99 Total views
Project posted by:

Proposals

Proposals Reputation Price offered

    There is no proposal yet.