Generally speaking, the file organization of "standard web pages" is XHTML CSS. XHTML is mainly used to represent web page structure and display content, while CSS is used to define structural layout and modify content styles.
XHTML commonly used for layout generally includes:
DIV: Mainly used for logical division of page content. For example, a web page generally includes responsible partitions such as header, navigation, sidebar, content and copyright. At this point you can use the DIV tag to split.
At the same time, it is recommended to name each block like this:
The following is the quoted content:
Header:
Navigation:
Sidebar:
Content:
Copyright:
Note: The ID is unique, that is, the ID must not appear more than twice on the same page. Otherwise use class.
ul: It is originally an unordered list and is often used to represent equivalent elements of non-structural classes in XHTML CSS applications. Need to be used in conjunction with the sub-element LI of UL.
The following is the quoted content:
span: If you compare this element with DIV, then span is a bag and div is a box (Xiao Yi: Basic Application of XHTML Code). In fact, div is a block-level element, and span is an inline element (see related inline (inline) elements and block-level elements). Through span, you can individually define a segment element in a paragraph or a row of elements.
For example:
The following is the quoted content:
-
(2006-11-13)Summary of XHTML application of XHML CSS layout
Defining span in css as left/right floating allows the date and title to be displayed on both sides. This is relative to using
The following is the quoted content:
- 2007-11-5jb51.net
- XHML CSS layout summary
Much simpler.
========================================
After talking about the common XHTML tags used for layout, there are also XHTML tags used to display web page content. for example:
The following is the quoted content:
represents an image
represents a hyperlink
(n=1,2,...,6) represents the page content title
It is recommended that h1-h6 decrease in order of importance, h1 is the most important title (see greengnn: div css naming reference)
Originally used
and
to represent bold and italic tags, choose to use
and
instead.