document.tags.textTransform

JavaScript 1.2+ Nav4+ Syntax

document.tags.tagName.textTransform

Description

The textTransform property specifies the transformation that should be applied to text as associated with the tag called tagName.

There are four types of values that are valid for the textTransform property: capitalize, uppercase, lowercase, and none.

Example

Listing 7.194 uses the textTransform property to capitalize the first letter of every word in the sentence.

Listing 7.194 Set the textTransform Property
 <html> <script> <!-- Hide //Create a style sheet tag that defines capitalization document.tags.P.textTransform = "capitalize"; //Hide End ---> </script> <p>This line demonstrates the ability to capitalize words.</p> </html> ...

Get Pure JavaScript now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.