1.1 Marking method in HTMl5
1. Content type
The file extension remains unchanged, it is still .htm or .htm, and the content type is "text/html"
2. DOCTYPE statement
<!DOCTYPE HTML>
3. Specify the encoding of characters
<meta charset = “utf-8”> (utf-8 is recommended)
1.2 HTML ensures compatibility with previous HTML versions
three aspects:
1. Marked elements can be omitted
The elements that do not allow the use of closing tags are: area, base, br, col, command, embed, hr, img, input, keygen, link, meta, param, source, track, wbr.
The end tag elements that can be omitted are: li, dt, dd, p, rt, rp, optgroup, option, colgroup, thread, tbody, tfoot, tr, td, th.
All marked elements that can be omitted are: html, head, body, colgroup, tbody.
All resources on this website are contributed and published by netizens, or reprinted by major download sites. Please check the integrity of the software yourself! All resources on this website are for learning and reference only. Please do not use them for commercial purposes, otherwise you will be responsible for all consequences incurred! If there is any infringement, please contact us to delete and remove it. Contact information: admin@php.cn