Javascript examples for CSS Style Property:textTransform
Transform all characters in a <p> element to uppercase:
<!DOCTYPE html> <html> <body> <p id="myP">This is an example paragraph.</p> <button type="button" onclick="myFunction()">Transform text</button> <script> function myFunction() {/* w w w . j a v a2 s . c o m*/ document.getElementById("myP").style.textTransform = "uppercase"; } </script> </body> </html>