Web development (c) CSS

Outline

basic concepts

Cascading Style Sheets ( Cascading Style Sheets ) , is responsible for the performance of the three elements of the pageto create a style sheet for the page, decorated by the style sheet of the page

Stack: web pages imagine multilayer structure, high levels of low-level coverage, CSS set styles for all levels

Stylesheet: collection of various styles, such as font, color, background, style positioning

grammar

A style sheet has a pattern structure, comprising a pattern selector and declaration block

Selector {
      Style Name: style value;
      Style Name: style value;
      Style Name: style value;
}  

Selector

  The selected element can be specified by the selector, and the declaration block style applied to the selector elements corresponding

Declaration block

  Immediately after the selector by a pair of {} enclose

  In a declaration block can be written a plurality of statements, declarations semicolon ; spaced

  Style name and style values by colons : connection

  Is actually a set of name-value pairs a group of structure

Note

  / * Footnotes * /

  css comments can only be written in the style tag or css files

  In the style label (label style tags are child's head) can be stored in the code css

The introduction of way

Guess you like

Origin www.cnblogs.com/dreamer-lin/p/11707793.html