HTML element Properties Test summary (sequel)

Source: Internet
Author: User


HTML element Properties Test summary (sequel)


The meaning of the code element (semantics) is "content", when FireFox renders the element, it will display the code tag content as "Equal width font" (the width of each character equals), resulting in the element's semantics and presentation form mixed together; the correct approach is that the browser should ignore code The default rendering effect (equal-width font) left by the element for historical reasons.

The semantic element simply describes the structure and meaning of the document content, such as code for the document, video for the document, and CSS to control the way these elements are presented to the user (the content of the code element is presented to the user in the same wide font), which separates the content from the presentation. For example, the following document:


<! Doctype html>


The rendering effect is as follows:


650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/6C/43/wKiom1VC7hOSLDV2AAHqJlxOn_I733.jpg "title=" Web194.png "alt=" Wkiom1vc7hosldv2aahqjlxon_i733.jpg "/>


650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/6C/40/wKioL1VC9pWhHdVeAAFVYJSLsMY655.jpg "title=" Web196.png "alt=" Wkiol1vc9pwhhdveaafvyjslsmy655.jpg "/>

Also, although Chrome will change the font style inside the code tag by default, its effect is not obvious and cannot differentiate between equal and non-equal width fonts, as follows:


650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M02/6C/44/wKiom1VC-EnwksJkAAPLMYm4Mto959.jpg "title=" Web197.png "alt=" Wkiom1vc-enwksjkaaplmym4mto959.jpg "/>


Summary: None of the above three browsers have implemented a concept that separates semantic elements from their rendering effects, and developers can change the "default" style of the code element through CSS.





This article is from the "free, equal, sharing, mutual help" blog, please be sure to keep this source http://shayi1983.blog.51cto.com/4681835/1641156

HTML element Properties Test summary (sequel)

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.