HTML CSS

[Chp.1.1] 프론트엔드 개발자 부트캠프 코딩 HTML CSS <div>, <span>, <style>, <hr>, <br>, <sub>, <sup>

개발박사 2024. 2. 13. 14:51

 

<div>: The Content Division element : generic container

https://developer.mozilla.org/en-US/docs/Web/HTML/Element/div

<div class="warning">

<img src="이미지이름.png" alt="ㄱㄴㄷㄹㅁㅂㅅ" />

<p>ㄱㄴㄷㄹㅁㅂㅅ</p>

</div>

------------

<span>: The Content Span element : generic inline container for phrasing content

https://developer.mozilla.org/en-US/docs/Web/HTML/Element/span

<p>

Add the <span class="ingredient">phd</span>, <span class="ingredient">doctor</span> and

<span class="ingredient">master</span> performance to develop the career.

<style>

span.ingredient {

color: #f00;

}

</style>

</p>

------------

<hr>: The Thematic Break (Horizontal Rule) element : hematic break between paragraph-level elements: for example, a change of scene in a story, or a shift of topic within a section

https://developer.mozilla.org/en-US/docs/Web/HTML/Element/hr

<br>: The Line Break element : a line break in text (carriage-return)

https://developer.mozilla.org/en-US/docs/Web/HTML/Element/br

<sub>: The Subscript element 아래첨자

https://developer.mozilla.org/en-US/docs/Web/HTML/Element/sub

<p>

C<sub>8</sub>H<sub>10</sub>N<sub>4</sub>O<sub>2</sub>

</p>

<sup>: The Superscript element 위첨자

<p>

<var>a<sup>2</sup></var> + <var>b<sup>2</sup></var> = <var>c<sup>2</sup></var>

</p>