My JavaScript code doesn't execute properly, what am I doing wrong?
I Need help figuring out why my code doesn't run properly!

This was the directions for the assignment:

   

 1. Create two input boxes, one to accept the price of an item and another to
    accept the number of items to order.
  
 2. Create one button to calculate the total.
        
 3. Use an alert message to tell them the total price or that the input
    data is invalid.  

 4. Use a function to validate that the price and number of items are
    numeric. 

 5. Once the data is valid, use a function that accepts two arguments,
    one for price and one for the number of items, to
    calculate the total and then displays the total price.

this is the code, how the instructor wants it setup! (what am I doing wrong that it isn't working correctly?)
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
	<head>
		
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		
		<title>Lab 8b: Stephanie Hussar</title>
		
		<script type="text/javascript">
		
			
			
			function verifyNumber(){
				
				if (!isNaN(parseFloat(document.Form1.itemPrice.value)) && (document.Form1.itemQuantity.value))
			  	return true;
			else
			   	return false;
			   }
			   
			function calculations(){
				
				var total;
				var itemPrice = document.Form1.itemPrice.value;
            	var itemQuantity = document.Form1.itemQuantity.value;
            	alert(itemPrice);
            	alert(itemQuantity);

            if( !verifyNumber(itemPrice) || !verifyNumber(itemQuantity)){
                alert( "Your numbers are incorrect! Please enter numerics only!" );
                return false;
            }

            total = itemPrice.value * itemQuantity.value;
            alert( "The total cost is: $" + total);
        }
				
		</script>
	
	</head>
	
	<body>
		
		<form id="Form1" name="Form1">
		
		<label for="itemPrice">Enter the Item Price:</label></b><br />
		<input type="text" id="itemPrice" /></b><br />
		<label for="itemQuantity">Enter the Item Quantity</label></b><br />
		<input type="text" id="itemQuantity"  />
		<br />
		<input type="button" id="totalSubmit" value="Total" onclick="calculations()" />
		
		</form>
		
	</body>
	
     </html>


My JavaScript code doesn't execute properly, what am I doing wrong?
===

I Need help figuring out why my code doesn't run properly!

This was the directions for the assignment:

   

 1. Create two input boxes, one to accept the price of an item and another to
    accept the number of items to order.
  
 2. Create one button to calculate the total.
        
 3. Use an alert message to tell them the total price or that the input
    data is invalid.  

 4. Use a function to validate that the price and number of items are
    numeric. 

 5. Once the data is valid, use a function that accepts two arguments,
    one for price and one for the number of items, to
    calculate the total and then displays the total price.

this is the code, how the instructor wants it setup! (what am I doing wrong that it isn't working correctly?)
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
	<head>
		
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		
		<title>Lab 8b: Stephanie Hussar</title>
		
		<script type="text/javascript">
		
			
			
			function verifyNumber(){
				
				if (!isNaN(parseFloat(document.Form1.itemPrice.value)) && (document.Form1.itemQuantity.value))
			  	return true;
			else
			   	return false;
			   }
			   
			function calculations(){
				
				var total;
				var itemPrice = document.Form1.itemPrice.value;
            	var itemQuantity = document.Form1.itemQuantity.value;
            	alert(itemPrice);
            	alert(itemQuantity);

            if( !verifyNumber(itemPrice) || !verifyNumber(itemQuantity)){
                alert( "Your numbers are incorrect! Please enter numerics only!" );
                return false;
            }

            total = itemPrice.value * itemQuantity.value;
            alert( "The total cost is: $" + total);
        }
				
		</script>
	
	</head>
	
	<body>
		
		<form id="Form1" name="Form1">
		
		<label for="itemPrice">Enter the Item Price:</label></b><br />
		<input type="text" id="itemPrice" /></b><br />
		<label for="itemQuantity">Enter the Item Quantity</label></b><br />
		<input type="text" id="itemQuantity"  />
		<br />
		<input type="button" id="totalSubmit" value="Total" onclick="calculations()" />
		
		</form>
		
	</body>
	
     </html>

