Application environment - CSS - use text transform attribute to convert English content to uppercase, lowercase, hump, etc

Text transformtext transform is a CSS attribute that represents the text transformation method. It has

text-transform

Text transform is a CSS attribute that represents the transformation method of text. It has the following possible values:

None: indicates that there is no conversion, and the original case and format are maintained.

Capitalize: it means to convert the first letter of each word to uppercase, and the rest to lowercase.

Uppercase: indicates that all letters in the text are converted to uppercase.

Lowercase: means to convert all letters in the text to lowercase.

Full width: It means to convert all characters in the text into full width characters, similar to the width of Chinese characters.

The following is an example of setting the text transform attribute through CSS code:

 p {  text-transform: uppercase;}

This code will make all

The text in the element is converted to uppercase letters.

It should be noted that text transform can only work on alphabetic characters and has no effect on other characters (such as numbers, punctuation marks, etc.).



comment