Code
Execute
<!DOCTYPE html> <html> <head> <title>html tutorial - html5 - html code - html form - In 30Sec by Microsoft Award MVP - | wikitechy HTML onblur attribute</title> </head> <body> Enter the text: <input type="text" id="txtname" onblur="Onblur()"> <script> function Onblur() { var a = document.getElementById("txtname"); a.value = a.value.toLowerCase(); } </script> </body> </html>
Result