Four css writing methods and four css writing methods
Priority: external style <internal style sheet <inline style sheet;
Priority, that is, the right of the selector with the same name will overwrite the left
1. Internal Style Sheets
<Head> <style>/* internal style table, which is generally used to overwrite public styles */# headTip {color: 0xff5 ;}</style>
2. Use the link tag to declare the use of external resources in the document. This is the most common method.
The css external style table specifies the encoded @ CHARSET = "UTF-8"; it must be placed in the first line.
<Head> <link href = "./my-common.css" rel = "stylesheet" media = "screen" type = "text/css"/>
3. @ method: Introduce css. Note that this is asynchronously loaded. It is loaded only after the entire html file is loaded, leading to page flashing. It is not recommended.
<Head> <style> @ import 'my-common.css '; </style>
4. inline style sheets have the highest priority and are straightforward, but they cannot be reused and are not easy to maintain.
<Body> <input type = "text" style = "color: 0x550; font-size: 30px;"/> </body>