What you need to know about html tags and page layout
零下一度Original
2017-04-27 13:35:431492browse
I didn’t lay a solid foundation in school, and now that I’m working after graduation, I pursue learning speed and mastering more knowledge too much, thus ignoring the details. As a result, the current foundation is not solid. . So, the foundation is very important, don’t be too eager for success, just take it step by step. Details determine fate. Celebrities say this, so it must be true.
## Let’s summarize:
一.html tag attention
1.html should be written legally, with good structure and semantics
2. Avoid excessive use of p and span, making the document easier to apply styles and clearer in logical paragraphs.
Use h1-6 tags according to importance, use p for paragraphs, and use ul for lists. Block-level elements cannot be nested in inline elements, which are descriptive. Form elements (input, tetarea) add label
3. Use labels as little as possible
4. Use class and id appropriately: the same class can appear repeatedly, and the same id can only appear once on a page
5. Title tag They are divided into: h1~h6, which indicate the priority order of titles in the document from high to low.
H1 is best used only once in a web page to modify the main title, usually the title of the web page. But in practice, h1 is used as a logo tag, close to the body, so that search engines can understand the theme quickly. h2 represents the article title or document subtitle;
h3 is the column title on the homepage of the website and other pages. H2, H3, and H4 tags can appear multiple times in a web page, but they need to be added at will or excessively.
6. In the form:
##
The above is the detailed content of What you need to know about html tags and page layout. For more information, please follow other related articles on the PHP Chinese website!
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn