I have the code below on a page I am building

Basically what I want to do is to have the last total field (with discounted price) show the value with 2 decimal places (for example 2.25 instead of 2.2535456)

Is this possible using JavaScript and if so could anyone point me in the right direction?



(my code follows>)

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script language="JavaScript">
function discounter() {

<form name="form1" method="post" action="">
<p>Item Price=
<input name="itemprice" type="text" onChange="return discounter()" id="itemprice" size="5">
<p> With Discounted Price=
<input name="discountedprice" type="text" disabled id="discountedprice3">
<input name="total" type="hidden" disabled id="total">