javascript auto uppercase


/ Published in: JavaScript
Save to your folder(s)



Copy this code and paste it in your HTML
  1. Test <input type="text" onkeydown="f(this)" onkeyup="f(this)" onblur="f(this)" onclick="f(this)" />
  2.  
  3. <script type="text/javascript">
  4. function f(o){o.value=o.value.toUpperCase().replace(/([^0-9A-Z])/g,"");}
  5. </script>

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.