Code for string conversion using the text-transform attribute in CSS

不言
Release: 2018-08-06 16:58:08
Original
2958 people have browsed it

The content of this article is about the code for string conversion using the text-transform attribute in CSS. It has certain reference value. Friends in need can refer to it. I hope it will be helpful to you.

<!DOCTYPE html><html><head>
    <meta charset="UTF-8">
    <title>字符转换</title>
    <style>
        p.none {            
        text-transform: none;        
        <!-- 正常 -->
        }

        p.uppercase {
            text-transform: uppercase;        
            <!-- 转大写 -->
        }

        p.lowercase {
            text-transform: lowercase;        
            <!-- 转小写 -->
        }

        p.capitalize {
            text-transform: capitalize;        
            <!-- 只对首字母大写 -->
        }    
        </style>
        </head>
        <body>
        <p class="none">This is a some Text.This is a some Text.</p>
        <p class="uppercase">This is a some Text.</p>
        <p class="lowercase">This is a some Text.</p>
        <p class="capitalize">This is a some Text.</p>
        </body>
        </html>
Copy after login

Recommended related articles:

Two ways to use tables in CSS (examples)

The concept of multi-column layout is What? Application of CSS multi-column layout (example code)

The above is the detailed content of Code for string conversion using the text-transform attribute in CSS. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!