We would like to know how to parse numbers mixed with letters.
<!DOCTYPE html>
<html>
<body>
<script type='text/javascript'>
<!--from ww w . j a v a 2 s .co m-->
var str="150px";
var str1 = (parseInt(str)+100)+"px";
document.writeln(str1);
</script>
</body>
</html>
The code above is rendered as follows: