var str = "I learn JavaScript";
// Display converted string, and original variable on 2nd line:
alert( str.toLowerCase() +"\n" + str );
var str = "I learn JavaScript";
str = str.toLowerCase(); // str variable now in minuscules!
alert( str );
.lowercased {
text-transform:lowercase;
}
<input type="text" name="emailAddress"
style="text-transform:lowercase"
onchange="this.value=this.value.toLowerCase()"
>
$emailAddress = strtolower( $emailAddress );
Sister / opposite method: get an all-caps copy of a string by using toUpperCase().