how to add two text box values?refer my code below. it is concatinating instead of adding. my code is
Code:
<html>
<head>
<script language="javascript">
function addone()
{
a=document.getElementById("h1").value
var b=a+1;
document.getElementById("h1").value=b;
}
</script>
</head>
<body>
<input type="text" id="h1"/>
<input type="button" value="ADD" onclick="addone()"/>
</body>
</html>
Comment