HTML チートシート
HTML チートシート。日常的に使用できるよう印刷できます。
HTML 基本ドキュメント
<!DOCTYPE html>
<html>
<head>
<title>文書タイトル</title>
</head>
<body>表示されるテキスト...</body>
</html>
基本タグ(Basic Tags)
<h1>最大の見出し</h1>
<h2> . . . </h2>
<h3> . . . </h3>
<h4> . . . </h4>
<h5> . . . </h5>
<h6>最小の見出し</h6>
<p>これは段落です。</p>
<br>(改行)<hr>(水平線)<!--これはコメントです-->
テキストの書式設定(Formatting)
<b>太字テキスト</b>
<code>コンピュータコード</code>
<em>強調テキスト</em>
<i>斜体テキスト</i>
<kbd>キーボード入力</kbd>
<pre>整形済みテキスト</pre>
<small>より小さいテキスト</small>
<strong>重要なテキスト</strong>
<abbr>(略語)<address>(連絡先情報)<bdo>(テキスト方向)<blockquote>(別のソースから引用された部分)<cite>(作品のタイトル)<del>(削除されたテキスト)<ins>(挿入されたテキスト)<sub>(下付きテキスト)<sup>(上付きテキスト)
リンク(Links)
通常のリンク:<a href="http://www.example.com/">リンクテキスト</a>画像リンク:<a href="http://www.example.com/"><img src="URL" alt="代替テキスト"></a>メールリンク:<a href="mailto:[email protected]">e-mailを送信</a>ブックマーク:<a id="tips">ヒント部分</a>
<a href="#tips">ヒント部分にジャンプ</a>
画像(Images)
<img src="URL" alt="代替テキスト" height="42" width="42">
スタイル/セクション(Styles/Sections)
<style type="text/css">
h1 {color:red;}
p {color:blue;}
</style>
<div>ドキュメント内のブロックレベル要素</div>
<span>ドキュメント内のインライン要素</span>
順序なしリスト
<ul>
<li>項目</li>
<li>項目</li>
</ul>
順序付きリスト
<ol>
<li>第1項目</li>
<li>第2項目</li>
</ol>
定義リスト
<dl>
<dt>項目 1</dt>
<dd>項目 1 の説明</dd>
<dt>項目 2</dt>
<dd>項目 2 の説明</dd>
</dl>
テーブル(Tables)
<table border="1">
<tr>
<th>テーブルの見出し</th>
<th>テーブルの見出し</th>
</tr>
<tr>
<td>テーブルのデータ</td>
<td>テーブルのデータ</td>
</tr>
</table>
フレーム(Iframe)
<iframe src="demo_iframe.htm"></iframe>
フォーム(Forms)
<form action="demo_form.php" method="post/get">
<input type="text" name="email" size="40" maxlength="50">
<input type="password">
<input type="checkbox" checked="checked">
<input type="radio" checked="checked">
<input type="submit" value="Send">
<input type="reset">
<input type="hidden">
<select>
<option>りんご</option>
<option selected="selected">バナナ</option>
<option>さくらんぼ</option>
</select>
<textarea name="comment" rows="60" cols="20"></textarea>
</form>
エンティティ(Entities)
<と同等<
> と同等>© は © と同等