I am trying to add ( SUM) a input value to a random number.
I want to display the SUM of these 2 values only after the input field is filled out, along with an instruction note that ask them to enter something in another input field.
Here's where I cant seem to get a sum.
var total = document.Addition.randomnumber.value + document.Addition.userInput.value;
document.getElementById('myDiv').innerHTML = total;
Your total is: <span id='myDiv'>
How can I get 'myDiv' to show the total. Its Concatenating rather than summing.
Code samples welcome.