Go to information

XHTML1.0 Strict DTD

<?xml version="1.0" encoding="Shift_JIS"?>

XML はデフォルトの文字コードに Unicode の "UTF-8"、または "UTF-16" が設定されているが、それ以外の文字コードを用いる場合は、HTTPヘッダなどで文字コード情報を設定している場合を除き、必ず当該文書で使う文字コードをその冒頭に XML宣言で追加指定しなければならない。

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

DOCTYPE宣言(文書型宣言)によってどんな文書型定義(DTD)に従った文書であるかを示す。XHTML1.0厳密型(Strict)DTD では W3C の仕様で「推奨しない」とされる要素や属性、さらにフレーム機能用の内容を使用しないことに従うことを意味する。

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="ja" lang="ja">
<head>
<base />
空要素
<link />
空要素
<meta />
content属性必須
空要素
<object>-</object>
他の内容よりも param要素を先行させるべき
  • param要素
  • ブロック要素
  • インライン要素
  • テキスト
<param />
name属性必須
空要素
<script>-</script>
type属性必須
スクリプト(PCDATA
<style>-</style>
type属性必須
スタイルシート(PCDATA)
<title>-</title>
head要素内に必ず1個だけ定義
テキストのみ(PCDATA)
</head>
<body>
ブロック要素
<address>-</address>
  • インライン要素
  • テキスト
<blockquote>-</blockquote>
ブロック要素
<div>-</div>
  • ブロック要素
  • インライン要素
  • テキスト
<dl>-</dl>
1個以上の dt要素, dd要素
<dt>-</dt>
  • インライン要素
  • テキスト
<dd>-</dd>
  • ブロック要素
  • インライン要素
  • テキスト
<fieldset>-</fieldset>
必ず最初に legend要素。legend要素の前は空白類文字しか許されない
  • legend要素
  • ブロック要素
  • インライン要素
  • テキスト
<legend>-</legend>
  • インライン要素
  • テキスト
<form>-</form>
action属性必須
  • ブロック要素(form要素の入れ子は禁止)
  • script要素
<h1-h6>-</h1-h6>
  • インライン要素
  • テキスト
<hr />
空要素
<noscript>-</noscript>
ブロック要素
<ol>-</ol>
1個以上の li要素
<li>-</li>
  • ブロック要素
  • インライン要素
  • テキスト
<p>-</p>
  • インライン要素
  • テキスト
<pre>-</pre>
  • インライン要素
  • テキスト
big要素, img要素, object要素, small要素, sub要素, sup要素は除く
<table>-</table>
  1. caption要素が0個、または1個。
  2. 0個以上の col要素、または 0個以上の colgroup要素。
  3. thead要素が0個、または1個。
  4. tfoot要素が0個、または1個。
  5. 1個以上の tbody要素、または1個以上の tr要素。
<caption>-</caption>
  • インライン要素
  • テキスト
<col>-</col>
空要素
<colgroup>-</colgroup>
<col>-</col>
空要素
<thead>-</thead>
1個以上の tr要素
<tr>-</tr>
1個以上の td要素, th要素
<td>-</td>
  • ブロック要素
  • インライン要素
  • テキスト
<th>-</th>
  • ブロック要素
  • インライン要素
  • テキスト
<tfoot>-</tfoot>
1個以上の tr要素
<tr>-</tr>
1個以上の td要素, th要素
<td>-</td>
  • ブロック要素
  • インライン要素
  • テキスト
<th>-</th>
  • ブロック要素
  • インライン要素
  • テキスト
<tbody>-</tbody>
1個以上の tr要素
<tr>-</tr>
1個以上の td要素, th要素
<td>-</td>
  • ブロック要素
  • インライン要素
  • テキスト
<th>-</th>
  • ブロック要素
  • インライン要素
  • テキスト
<tr>-</tr>
1個以上の td要素, th要素
<td>-</td>
  • ブロック要素
  • インライン要素
  • テキスト
<th>-</th>
  • ブロック要素
  • インライン要素
  • テキスト
<ul>-</ul>
1個以上の li要素
<li>-</li>
  • ブロック要素
  • インライン要素
  • テキスト
インライン要素
<a>-</a>
  • インライン要素(a要素の入れ子は禁止)
  • テキスト
<abbr>-</abbr>
  • インライン要素
  • テキスト
<acronym>-</acronym>
  • インライン要素
  • テキスト
<b>-</b>
  • インライン要素
  • テキスト
<bdo>-</bdo>
dir属性必須
  • インライン要素
  • テキスト
<big>-</big>
  • インライン要素
  • テキスト
<br />
空要素
<button>-</button>
  • ブロック要素
  • インライン要素
  • テキスト
a要素, button要素, fieldset要素, form要素, input要素, label要素, select要素, textarea要素を除く
<cite>-</cite>
  • インライン要素
  • テキスト
<code>-</code>
  • インライン要素
  • テキスト
<del>-</del>
body要素やブロック要素のみを内包できる要素の直接の子要素として直下に含めることもできる
インライン要素の内容になっている場合、ブロック要素を内容に含ませるのは不適切
  • ブロック要素
  • インライン要素
  • テキスト
<dfn>-</dfn>
  • インライン要素
  • テキスト
<em>-</em>
  • インライン要素
  • テキスト
<i>-</i>
  • インライン要素
  • テキスト
<img />
  • src属性必須
  • alt属性必須
空要素
<input />
空要素
<ins>-</ins>
body要素やブロック要素のみを内包できる要素の直接の子要素として直下に含めることもできる
インライン要素の内容になっている場合、ブロック要素を内容に含ませるのは不適切
  • ブロック要素
  • インライン要素
  • テキスト
<kbd>-</kbd>
  • インライン要素
  • テキスト
<label>-</label>
  • インライン要素(label要素の入れ子は禁止)
  • テキスト
<map>-</map>
id属性必須
  • area要素
  • ブロック要素
<area>-</area>
alt属性必須
空要素
<object>-</object>
他の内容よりも param要素を先行させるべき
  • param要素
  • ブロック要素
  • インライン要素
  • テキスト
<param />
name属性必須
空要素
<q>-</q>
  • インライン要素
  • テキスト
<samp>-</samp>
  • インライン要素
  • テキスト
<script>-</script>
type属性必須
body要素やブロック要素のみを内包できる要素の直接の子要素として直下に含めることもできる
スクリプト(PCDATA)
<select>-</select>
1個以上の option要素, optgroup要素
<option>-</option>
テキストのみ(PCDATA)
<optgroup>-</optgroup>
label属性必須
1個以上の option要素
<option>-</option>
テキストのみ(PCDATA)
<small>-</small>
  • インライン要素
  • テキスト
<span>-</span>
  • インライン要素
  • テキスト
<strong>-</strong>
  • インライン要素
  • テキスト
<sub>-</sub>
  • インライン要素
  • テキスト
<sup>-</sup>
  • インライン要素
  • テキスト
<textarea>-</textarea>
  • cols属性必須
  • rows属性必須
テキストのみ(PCDATA)
<tt>-</tt>
  • インライン要素
  • テキスト
<var>-</var>
  • インライン要素
  • テキスト
</body>
</html>

補足事項

現在位置
  1. W3G
  2. XHTML
  3. 解説
  4. XHTML1.0 Strict DTD
ナビゲーション
ステータス情報
作者
上田 遼
公開
2005-08-05T18:58:02+09:00
更新
2008-12-29T04:27:07+09:00
URI
http://w3g.jp/xhtml/guide/xhtml1_strict
検索