What's not right
Hello ! I can't find a mistake in this simple code!!
unfortunately id doesn't do what I need
It supposed to receive 2 numbers and throw an alert with a multiplication of those numbers.
pls point me to a mistake
<title> Test </title>
<h1 align= "center"> Calc </h1>
var a= document.Calc.li1.value;
var b= document.Calc.li2.value;
var c= (a*b);
alert("the answer is :"+c);
<input type="text" id="li1" name="L1">
<input type="text" id= "li2"name="L2">
<input type="submit" name="sbm" value="go" onclick= "mult()">
var a= parseInt(document.getElementById('li1').value);
var b= parseInt(document.getElementById('li2').value);
Thank you very much!
At least 98% of internet users' DNA is identical to that of chimpanzees
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)