Javascript examples for DOM HTML Element:Input Password
Input Password size Property - Get the width of a password field:
<!DOCTYPE html> <html> <body> Password: <input type="password" id="myPsw"> <button onclick="myFunction()">Test</button> <script> function myFunction() {// w w w . j av a2 s. c om var v = document.getElementById("myPsw").size; console.log(v); } </script> </body> </html>