亚洲国产日韩欧美一区二区三区,精品亚洲国产成人av在线,国产99视频精品免视看7,99国产精品久久久久久久成人热,欧美日韩亚洲国产综合乱

目錄 搜索
Attributes accesskey (attribute) class (attribute) contenteditable (attribute) contextmenu (attribute) data-* (attribute) dir (attribute) draggable (attribute) dropzone (attribute) Global attributes hidden (attribute) id (attribute) itemid (attribute) itemprop (attribute) itemref (attribute) itemscope (attribute) itemtype (attribute) lang (attribute) slot (attribute) spellcheck (attribute) style (attribute) tabindex (attribute) title (attribute) translate (attribute) Elements a abbr address area article aside audio b base bdi bdo blockquote body br button canvas caption cite code col colgroup data datalist dd del details dfn dialog div dl dt em embed fieldset figcaption figure footer form h1 head header hr html i iframe img input input type="button" input type="checkbox" input type="color" input type="date" input type="datetime"-local input type="email" input type="file" input type="hidden" input type="image" input type="month" input type="number" input type="password" input type="radio" input type="range" input type="reset" input type="search" input type="submit" input type="tel" input type="text" input type="time" input type="url" input type="week" ins kbd label legend li link main map mark menu menuitem meta meter nav noscript object ol optgroup option output p param picture pre progress q rp rt rtc ruby s samp script section select slot small source span strong style sub summary sup table tbody td template textarea tfoot th thead time title tr track u ul var video wbr Miscellaneous Attributes Block-level elements CORS enabled image CORS settings attributes Element Inline elements Kinds of HTML content Link types Microdata Optimizing your pages for speculative parsing Preloading content Reference Supported media formats Using the application cache Obsolete acronym applet basefont big blink center command content dir element font frame frameset hgroup image input type="datetime" isindex keygen listing marquee nextid noframes plaintext strike tt xmp
文字

HTML(超文本標記語言)元素通常是“塊級”元素或“內聯”元素。塊級元素占據其父元素(容器)的整個空間,從而創(chuàng)建一個“塊”。本文有助于解釋這意味著什么。

瀏覽器通常在元素之前和之后用換行符顯示塊級元素。你可以將它們想象成一堆盒子。

一個塊級元素總是從一個新行開始,占用全部可用的寬度(盡可能地向左和向右伸展)。

以下示例演示了塊級元素的影響:

塊級元素

HTML

<p>This paragraph is a block-level element; its background has been colored to display the paragraph's parent element.</p>

CSS

p { background-color: #8ABB55; }

用法

  • 塊級元素可能只出現在<body>元素中。

Block-level vs. inline

塊級元素和內聯元素之間有幾個關鍵的區(qū)別:

格式化默認情況下,塊級元素以新行開始,但內聯元素可以從行中的任何位置開始。內容模型一般而言,塊級元素可能包含內聯元素和其他塊級元素。在這種結構性區(qū)分中固有的概念是塊元素創(chuàng)建“更大”的結構比內聯元素。

塊級和內聯元素的區(qū)別在4.01以下的HTML規(guī)范中使用。在HTML5中,這種二元區(qū)別被更復雜的一組內容類別所取代?!皦K級”類別大致對應于HTML5 中流量內容的類別,而“內聯” 類別對應于短語內容,但還有其他類別。

元素

以下是所有HTML塊級元素的完整列表(盡管“塊級”在技術上未定義為HTML5中新增的元素)。

<address>聯系信息。  <article> HTML5   文章內容。  <aside> HTML5   Aside內容。<blockquote>長(“塊”)報價。  <canvas> HTML5   繪圖畫布。<dd>在描述列表中描述一個術語。<div>文檔部門。<dl>說明列表。<dt>說明列表術語。<fieldset>字段設置標簽。    <figcaption> HTML5   圖標題。  <figure> HTML5將   媒體內容與標題分組(請參閱<figcaption>)。  <footer> HTML5   部分或頁面頁腳。<form>輸入表單。  <h1>,<h2>,<h3><h4>,<h5><h6>  標題級別1-6。  <header> HTML5   部分或頁面標題。  <hgroup> HTML5  組頭信息。<hr>橫向規(guī)則(分界線)。<li>項目清單。<main>包含此文檔特有的中央內容。<nav>包含導航鏈接。   <noscript>不支持或關閉腳本的內容。<ol>有序列表。  <output> HTML5   表單輸出。<p>段。<pre>預先格式化的文本。    網頁的<section> HTML5部分。<table>表。<tfoot>表頁腳。<ul>無序列表。  <video> HTML5   視頻播放器。

上一篇: 下一篇: