Four ways to describe CSS

Source: Internet
Author: User

Priority: External style < internal style sheet < inline style sheet;

Priority, that is: the right side of the selector with the same name overrides the left

1. Internal style sheet




2. Use the link tag to declare one of the most common ways to use external resources in a document.

The CSS external style sheet specifies the encoded @charset= "Utf-8"; Need to be placed on the first line.




3.@ the way, the introduction of CSS, note that this is asynchronous loading, after the entire HTML loaded before loading, will cause the page to blink. It is not recommended.




4. Inline style sheet, the highest priority is the most straightforward, but not reusable is not easy to maintain.

<body>           <input type= "text" style= "color:0x550;font-size:30px;" />       </body>



The above is a small series for everyone to bring about the CSS of the four kinds of writing (must see article) all the content, I hope you have a lot of support script home ~

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.