亚洲国产日韩欧美一区二区三区,精品亚洲国产成人av在线,国产99视频精品免视看7,99国产精品久久久久久久成人热,欧美日韩亚洲国产综合乱

CSS styles

CSS styles: inline style, internal style, external style

New 03-three.html file:

<!doctype html>
<html>
   <head>
      <meta charset="UTF-8">
      <title>使用CSS樣式,樣式優(yōu)先級(jí),CSS選擇器</title>
      <style type="text/css">
         h1{
            color:blue;
            font-size:36px
         }
      </style>
   </head>
   <body>
      <link rel="stylesheet" href="03-three.css" />
       <p style="font-size:48px;color:red">段落文本(p):使用內(nèi)聯(lián)樣式</p>
      <h1>一級(jí)標(biāo)題(h1):使用內(nèi)部樣式表</h1>
      <h2>二級(jí)標(biāo)題(h2):使用外部樣式表</h2>
   </body>
</html>

Create a new 03-three.css file:

h2{
   color:green;
   background-color:gray
}

Run 03-three.html and the display will be as follows:

微信圖片_20180314161821.png

The priority of inline styles is the highest. Internal styles and external styles depend on which one is loaded last. The one loaded later will generally take effect.

But after adding !important, the priority becomes the highest


Continuing Learning
||
<?php echo "CSS樣式:內(nèi)聯(lián)樣式,內(nèi)部樣式,外部樣式";
submitReset Code