JavaScript Convert String to Integer
home
Run
screen_rotation
fullscreen
cloud_download
navigate_next
<html> <head> <title>Javascript Demo</title> <script type="text/javascript"> function convertInt() { var a = "10a"; // string var result = parseInt(a); alert(result); } </script> </head> <body> <a href="javascript:void(0)" onclick="convertInt()">Check </a> </body> </html>
<html> <head> <title>Javascript Demo</title> <script type="text/javascript"> function convertInt() { var a = "10a"; // string var result = parseInt(a); alert(result); } </script> </head> <body> <a href="javascript:void(0)" onclick="convertInt()">Check </a> </body> </html>
Copyrights@tutorialsplane.com