文字実態参照
![](https://tumaboki.com/wp-content/uploads/2020/10/simon-abrams-k_T9Zj3SE8k-unsplash-1024x683.jpg)
文字実態参照は、HTMLで使われる記号を文書内で使用するときに使います。
主な4つを紹介します。
- < は <
- > は >
- & は &
- “(ダブルクオテーション) は "
preタグを使えば、改行や空白をそのまま表現できます。
補足:「pre」とは「preformatted text(整形済みテキスト)」の略です。
合わせてcodeタグで囲ってあげると、さらにGoodです!
![](https://tumaboki.com/wp-content/uploads/2020/10/6e4ad4ab207dab45ac74cd50872c2892.png)
![](https://tumaboki.com/wp-content/uploads/2020/10/65356e1f4f25f3de7145920297610ecf.png)
リスト
![](https://tumaboki.com/wp-content/uploads/2020/10/daiga-ellaby-HwZQGB-ZjG4-unsplash-1024x683.jpg)
リストは3種類あります。
箇条書きリスト
ulタグ
unordered listの略
unordered:順序不要
liタグ
list itemの略
順序付きリスト
olタグ
ordered listの略
ordered:順序
liタグ
list itemの略
説明リスト
dlタグ
description listの略
description:説明
dtタグ
description termの略
term:期間
ddタグ
description detailの略
detail:詳細
![](https://tumaboki.com/wp-content/uploads/2020/10/24c29706bf2a18920ce17e3d68fe741a.png)
![](https://tumaboki.com/wp-content/uploads/2020/10/fa3bfed2bd0544cfe8c60aa734077aae.png)
表
![](https://tumaboki.com/wp-content/uploads/2020/10/brooke-cagle-g1Kr4Ozfoac-unsplash-1024x683.jpg)
表をマークアップするには、たくさんのタグを使います。
tableタグで、全体を囲います。
theadタグで、表の見出し全体を囲います。
theadは、table headの略です。
tbodyタグで、表の中身全体を囲います。
tbodyは、table bodyの略です。
trタグで、それぞれの行を囲います。
trは、table rowの略です。
thタグで、それぞれの見出し要素を囲います。
thは、table header cellの略です。
tdタグで、それぞれの表要素を囲います。
tdは、table data cellの略です。
![](https://tumaboki.com/wp-content/uploads/2020/10/9d57f715513791ecfa4c6629cced8599.png)
![](https://tumaboki.com/wp-content/uploads/2020/10/018e4d9c097ecb19a165e3086278f401.png)
わたしの考え
![](https://tumaboki.com/wp-content/uploads/2020/10/alex-geerts-NuO6iTBkHxE-unsplash-1024x683.jpg)
リストや表も見る方は簡単ですが、裏では細やかな作業が隠れていますね。
こういうことが知れるのもプログラミング学習の醍醐味だと思います。
コメント