02-CSS basic and advanced video -day1- 293

 

03 hyperlink selector abbreviated .html

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <style>
        /*相当于a:link styles of unvisited link {
        A* /
            -size font : 16px ; 
            font-weight : 700 ; 
            Color : Gray ; 
        } 
        / * there: this is the pseudo-class * / 
        / * mouseover effects * /       
        A: hover { 
            Color : Red ; 
        } 
    </ style > 
< / head > 
< body > 
    < A the href = "#" > spike </ A > 
</ body > 
</ HTML>

04 Structure pseudo class selector .html

 

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <style>
        /*
         li:first-child {
             color: blue;
         }

         li:last-child {
             color: green;
         }

          Selecting a third child * / 
         / * Li: Child-Nth (. 3) {
             color: yellow;
         }
         * / 
         / * N-Li 2 0 1 Number numbering from 1 * / 
         / * Li: Child-Nth (2N-1) {
             color: skyblue;
         } * / 
         / * ODD odd
         li:nth-child(odd) {
             font-size: 20px;
         }
            even the even
         li:nth-child(even) {
             font-size: 30px;
         }
         */
         /* 倒数*/
         li:nth-last-child(even) {
             color: red;
         }
    </style>
</head>
<body>
    <ul>
        <li>aaaaa</li>
        <li>bbbbbb</li>
        <li>ccccc</li>
        <li>ddddddddd</li>
        <li>eeeeee</li>
        <li>ffffff</li>
    </ul>
</body>
</html>

 

Reproduced in: https: //www.cnblogs.com/HiJackykun/p/11033082.html

Guess you like

Origin blog.csdn.net/weixin_33958585/article/details/93407457