js code working in editor but not on live site
<p>I've created a simple shopping cart total calculator with JS (super simple order form) but I can't get the JS code to work in a live browser however it works in my editor (Coda 2). the code is: </p>

<pre><code>function CalcTotal()
{

var quantity = eval(document.bookorderform.bookqty.value);
if (quantity == undefined) {quantity = 0}
var orderTotal = eval(quantity * 14.99) + (3.99);
document.bookorderform.total.value=orderTotal;

}
</code></pre>

<p>the test live environment is at: 
<a href="http://leapingbutterfly.org/bookorder.php" rel="nofollow">http://leapingbutterfly.org/bookorder.php</a></p>

<p>*I do not have the styling or the php code in there finished yet, however this should not be interfering with the js code. </p>

<p>I've double and tripple checked to make sure the code is the same as the one in my dev environment, also my form variables math their respective js variables. Only thing I can think of is if I'm not calling the document correctly, but i've called docs like this before with no problem. any help is greatly appreciated!  </p>
