Html+css
Html:hypertext Markup Language Hypertext Markup Language definition document structure
Css:cascading style Sheets Cascading style sheets define style type (appearance)
页面表示基础、可以控制布局、控制页面渲染
HTML terminology
Comments
Used to describe (description) the code functionality. The browser does not parse and display
Elements:
构成网页的基础单位。网页由大量的元素组成。
Element composition:
<开始标签>元素内容</结束标签>属性是对元素附加的功能。
Element categories: Double label and single label
Element nesting: Parent element, child element, sibling element, descendant element
Document Declaration DOCTYPE
Not declared will be parsed with a lower version of the HTML protocol. Also called weird mode.
HTML Lang Property
Head header tag to depict additional information about a Web page
- Meta tags are used to mark other source data (charset, keywords, viewport, author)
- Link tag for connecting to other files (CSS)
- The script tag is used to connect other files (CSS) or embedded JavaScript in the head.
- The style label is used to write the head style.
- Title Tag page header.
BODY element
Page body is the page display content
CSS Reference classification
- Internal style
The style tag in head that writes CSS styles directly to the HTML header
- External styles
Write CSS in a separate CSS file, referencing it with the link tag
- inline style
Written in the tag's Start tab for individual label modification styles
It is recommended to use external styles to facilitate reuse and maintenance
Weight: The maximum in-line style weights, and the position in the head determines the weights of the inner and outer styles
Terms
Comments
Features to describe the code
/* 注释 */
- Rules
- Selector Selector
- Element selector: Application of the same element
- Class selector: All matching classes are applied
- ID Selector: Uniquely matched element applied
- Naming rules:
HTML semantics
html5中新增的元素,与div相同的作用 但是能直接体现出意义
HTML Semantic structured elements
- Header Head
- Nav Navigation
- aside sidebar
- Ariticle Articles
- Section A whole or a part
- Footer Bottom
HTML elements
Element a
链接标签属性:href url
- Jump to a new page
- Anchor Point function
- function link (tel, mailto), invoking the functions implemented by the system software.
HTML Basics (1)