자주 쓰지 않았던 HTML Tags

Ellin.Kim·2025년 1월 20일

HTML/CSS

목록 보기
3/4
post-thumbnail

Blockquote

: 긴 인용문

<div>
  <blockquote cite="https://www.huxley.net/bnw/four.html">
    <p>Words can be like X-rays, if you use them properly—they’ll go through anything. You read and you’re pierced.</p>
  </blockquote>
  <p>—Aldous Huxley, <cite>Brave New World</cite></p>
</div>

q

: 짧은 인용문 - 줄바꿈 없는 짧은 인용문에 적합.

<p>
  When Dave asks HAL to open the pod bay door, HAL answers:
  <q cite="https://www.imdb.com/title/tt0062622/quotes/?item=qt0396921&ref_=ext_shr_lnk">
    I'm sorry, Dave. I'm afraid I can't do that.
  </q>
</p>

pre

: 텍스트를 공백과 줄바꿈을 포함해 그대로 표시. HTML에 작성한 내용 그대로 표현.

<pre>
This text
    is displayed
exactly as typed.
</pre>

mark

: 강조나 하이라이트

<p>This is a <mark>highlighted</mark> text.</p>

dl,dt,dd

: 정의 리스트를 만들 때 사용

<dl>
  <dt>HTML</dt>
  <dd>A markup language for creating web pages.</dd>
  <dt>CSS</dt>
  <dd>Styles the layout of web pages.</dd>
</dl>

HTML 요소 더 보기


💬 처음에 HTML 요소를 보고는 이걸 언제 다 외우나, 어떻게 쓰나 했는데 오랜만에 다시 보니 개발할 때 85%정도는 써본 것 같다. 뿌듯.
위 5개는 안 써본 것 중, 개발하며 쓰게 될 수도 있을 것 같은 tag들을 정리했다.

0개의 댓글