的用途是什麼和元素?它們為什麼被引入?
元素 <section> 和 <article> 也對螢幕閱讀器有用,並幫助視障使用者閱讀你的網頁內容。這些元素也對電子書閱讀器有益處。
讓我們看看如何使用這兩個元素。
<section>
<!DOCTYPE html> <html> <head> <title>HTML Section Tag</title> </head> <body> <section> <h1>Java</h1> <h3>Inheritance</h3> <p>Inheritance defines the relationship between superclass and subclass.</p> </section> </body> </html>
<article>
<!DOCTYPE html> <html> <body> <main> <h1>Learning</h1> <p>Learn to gain experience and try to share your knowledge with others.</p> <article> <h3>Web Development Tutorials</h3> <p>Consist of CSS, HTML, and PHP tutorials for 2nd Semester exams.</p> </article> <article> <h3>Academic Tutorials</h3> <p>Consist of Computer Fundamental, Computer Network tutorials for 1st Semester exams.</p> </article> </main> </body> </html>
廣告
資料結構
網路
RDBMS
作業系統
Java
iOS
HTML
CSS
Android
Python
C 程式設計
C++
C#
MongoDB
MySQL
Javascript
PHP