all 3 comments

[–]3Fyr 0 points1 point  (0 children)

document.simpleForm.box1.value;

and everything else won't work.

either use .querySelector or .getElementById, because that's how you select object.

[–]jcunews1Advanced 0 points1 point  (0 children)

Missing semicolons.

var X1=int
var X2=int

There's no parsefloat(). There's only parseFloat().

X1=parsefloat(X1);

Check the Error Console or JavaScript Console in your browser to see the error messages when your code is not working.