Introduction to XHTML tag semantics _ HTML/Xhtml _ webpage Creation

Source: Internet
Author: User
I attended a WD training organized by the company two days ago. One Class talked about tag semantics. After listening, I felt very useful and corrected my previous incorrect views on HTML and CSS. First, we can use visual Division to determine the meaning of the content. The search engine only sees the code. The search engine can only use tags to determine the meaning of the content. I have never paid much attention to search engines before, and now I am very concerned about it, because a large part of the page traffic comes from search engines. To make the pages as friendly as possible to search engines, so we need to make tags semantic as much as possible.

In the past, with my superficial understanding of web development, I thought that to write a good page that complies with the standard, I only need to separate the structure and performance, and then do not use labels such as table and font, as for the entire article, I don't think there is any problem because CSS is very powerful. However, all tags have their own semantics. The following describes the semantics of some tags:

P semantics: Division (separated)

Span semantics: Span (range)

Ol Syntax: Ordered List (sort List)

Ul Syntax: Unordered List (Unordered List)

Li Syntax: List Item (List Item)

............

If you ignore the tag semantics and default style, all tags use p. In fact, you can also write a page with good visual effects, as long as you use CSS flexibly. However, even though the visual requirements are met, the entire page does not have any semantics and the search engine still cannot understand it. Therefore, remember:

Structure (html) is the focus, and style (css) is used to modify the structure. Therefore, you must first determine the html, tag, and then select the appropriate css.

Generally, all labels have a default style. Therefore, a simple way to determine whether the webpage tag semantics is good is to remove the style and check whether the webpage structure is organized and orderly, whether it still has good readability.

In addition, it is worth mentioning that the h tag is the title, and the search engine is sensitive to this tag, especially h1, and h2. For a page with good semantics, the h tag should be complete and orderly without faults. That is to say, we need to push down h1, h2, h3, h4 like this. Do not use h1, h3, h4, or Miss h2. For a well-structured webpage, the h tag can organize an outline of the webpage.

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.