Summary of beginner CSS course on September 9.5, 9.5css

Source: Internet
Author: User

Summary of beginner CSS course on September 9.5, 9.5css

Learning Summary
Html 5

Attributes under the vido tag and audio Tag: the controls playback control loop playback autoplay automatic playback

 

CSS

Differences between block-level elements and intra-row Elements
I. block-level element: block element
By default, each block-level element occupies the height of a row. After a block-level element is added to a row, other elements cannot be added (except after float ). When two block-level elements are continuously edited, the line feed is automatically displayed on the page. Generally, block-level elements can be nested with block-level elements or intra-row elements;
Block-level elements are generally used as containers to organize structures, but not all of them are. Some block-level elements, such as <form>, can only contain block-level elements. Other block-level elements can contain row-level elements, such as <P>. Some can contain both block-level and row-level elements.
DIV is the most commonly used block-level element. The display: block of element styles are block-level elements. They are always displayed in the form of a block, and the sibling blocks of the same level are arranged in vertical order, and the left and right are full.

2. Line element
It is also called inline element and embedded element. In-line elements are generally basic elements based on the semantic level (semantic) and can only accommodate text or other inline elements. Common inline elements are "". For example, the SPAN element, IFRAME element, and the display: inline element of the element style are all intra-row elements. For example, elements such as text are arranged horizontally between letters and automatically folded to the rightmost end.

Iii. Features of block elements
① Always start on a new line;
② Height, row height, and outer and inner margins can be controlled;
③ The default width is 100% of its container unless a width is set.
④ It can accommodate inline elements and other block elements

Iv. Features of inline Elements
① And other elements are on one line;
②. High: The Row Height, outer margin, and inner margin cannot be changed;
③ The width of a text or image cannot be changed.
④ Inline elements can only contain text or other inline Elements

Note the following for line elements:
The width setting is invalid.
The height setting is invalid. You can use line-height to set the height.
Only the left and right margin values are valid when you set margin.
When padding is set, only the left and right padding are valid, and the up and down are invalid. Note that the element range is increased, but it does not affect the content around the element.

Priorities of CSS style import methods
The highest embedded priority. Other import methods take precedence over the specific location.

CSS Selector

ID Selector
CLASS Selector
Element Selector
Descendant Selector
Child element Selector
Adjacent sibling Selector
Wildcard Selector

At present, the reset resetting Technology in the novice stage is implemented through the wildcard * {}.

In the future, normalize may be used to replace the reset technology.

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.