This article mainly introduces to you the definition and usage of the new tag figure taginhtml5.
HTML5 is the latest revised version of HTML, using richer tags to give web pages better meaning and structure. So some newcomers may ask, what is thisfigure tag?When should the figure tag be used?
The above code introduces you to an example of using the figure tag. The effect of accessing through the front desk is as follows:
As mentioned before, figure specifies independent streaming content photos and images. etc. In other words, the figure tag can be used to represent an independent piece of content on the website production page. Removing it from the web page will not affect other content on the web page. The content represented by figure can be a picture, statistical chart or code example.
As shown in the picture above, the pictures and titles in the figure tag are displayed independently.
Note:
The content of the figure element should be related to the main content, but if removed, it should have no impact on the document flow.
You can use the
element to add a caption to a figure.
This article is an introduction to how to use the new tag figure in HTML5. It should be very simple and easy to understand. I hope it will be helpful to friends in need!
If you want to know more about front-end knowledge, you can follow PHP Chinese websiteHTML5 tutorialand other related front-end video tutorials!
The above is the detailed content of What is the figure tag? When to use it?. For more information, please follow other related articles on the PHP Chinese website!
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