html中style属性的常见用法

html中style属性的常见用法

 <h2 style=" color: rgb(17, 119, 0);">>
    ~~~
 </h2>
 <!-- 这里表示二级标题文字的背景颜色为黄色-->
 
 <p style="color:green ;font-family:verdana;font-size:20px">
    ~~~
 </p>
 <!-- 这里设定了段落内文字的颜色、字体和字号 -->
 
 <h1 style="text-align:center">
    ~~~
 </h1>
 <!-- 这里表示一级标题的文本对齐方式为居中对齐 -->
 
 

 

posted @ 2020-10-18 14:57  DBeau  阅读(802)  评论(0)    收藏  举报