CSS attribute writing Sequence

Source: Internet
Author: User

Every time CSS is written, it will pause, and how to write the sequence under the Organization, without careful analysis. After a long time, it will form the default habit, purely for the convenience of searching and rewriting, this is probably the case:

Position:; <br/> margin:; <br/> padding:; <br/> width:; <br/> Height:; <br/> border :; <br/> Background:; </P> <p> color:; <br/> font-size:; <br/> Z-index :; <br/> display :;

I only listed some of the commonly used ones. I read "The writing sequence of attributes in CSS", and I think the analysis is good.

 

 

  1. Attributes that affect the Document Stream (such as display, position, float, clear, visibility, and table-layout)
  2. Attributes of the Self-box model (such as width, height, margin, padding, and border)
  3. Typographical attributes (such as font, line-height, text-align, text-indent, vertical-align, and so on)
  4. Decorative attributes (such as color, background, opacity, and cursor)
  5. Attributes of the generated content (such as content, list-style, and quotes)

 

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.