This might be a very simple quesion. But I simply haven't been able to find the answer googling around.
I was wondering if there was a way that I could get the int value of a textfield instead of just the value.
Html:
<input id="Price" type="number" value="" placeholder="Price" />
JavaScript:
var oCar =
{
"Price": $('#Price').val()
}
Let's fx. say that I then add a speed property to the car. And later, I would then like to call it in an animate function like = "oCar.Speed".
$(".Car").animate({
//some animation
}, oCar.Speed, function() {
});
Then it's wouldn't work since the speed would be a string.