πŸ“

7. Text-level semantics

Β 
Β 
Β 

<br>, <wbr>

<br> νƒœκ·ΈλŠ” μ€„λ°”κΏˆμ„ μœ„ν•œ νƒœκ·Έμž…λ‹ˆλ‹€. <wbr> νƒœκ·Έλ„ κ°„ν˜Ή μ‚¬μš©ν•˜λŠ”λ°μš”. <wbr>은 ν…μŠ€νŠΈ λ°•μŠ€μ—μ„œ ν•œ μ€„λ‘œ λͺ¨λ‘ ν‘œμ‹œκ°€ μ•ˆλ  λ•Œμ—λ§Œ μ€„λ°”κΏˆμ΄ μΌμ–΄λ‚˜κ²Œ ν•˜λŠ” κ²ƒμž…λ‹ˆλ‹€.
<p> <!-- 곡백병합 --> Lorem ipsum <br> <br> <br> dolor sit amet <p>풀밭에 같지 전인 λ…Έλ…„μ—κ²Œμ„œ 청좘의 방지. <wbr> 전인 μ—΄λ½μ˜ 풀이 것이닀.</p> </p>
Β 
Β 

<a href="경둜">

<a> μš”μ†ŒλŠ” HTML의 핡심적인 μš”μ†Œλ‘œμ¨ ν•˜μ΄νΌ ν…μŠ€νŠΈ 즉, 링크λ₯Ό λ§Œλ“€ λ•Œ μ‚¬μš©ν•©λ‹ˆλ‹€.
href 속성을 톡해 경둜λ₯Ό 지정할 수 μžˆμŠ΅λ‹ˆλ‹€. href 속성을 μ‚¬μš©ν•˜μ§€ μ•Šκ³  μžλ°”μŠ€ν¬λ¦½νŠΈλ‘œ 경둜λ₯Ό 지정할 μˆ˜λ„ μžˆμ§€λ§Œ μ΄λŠ” μ›Ή 접근성에 μœ„λ°°λ¨μœΌλ‘œ href 속성을 μ‚¬μš©ν•΄μ£ΌλŠ”κ²Œ μ’‹μŠ΅λ‹ˆλ‹€.
html 문법상 λΈ”λ‘λ ˆλ²¨ μš”μ†ŒλŠ” 인라인 μš”μ†Œμ˜ μžμ‹μœΌλ‘œ μ‚¬μš©λ˜μ§€ μ•Šμ§€λ§Œ, 액컀 νƒœκ·Έλ§Œ μ˜ˆμ™Έμ μœΌλ‘œ 블둝 레벨 μš”μ†Œλ₯Ό μžμ‹μœΌλ‘œ ν•˜λŠ”κ²ƒμ΄ ν—ˆμš©λ©λ‹ˆλ‹€.
λ˜ν•œ a μš”μ†Œμ•ˆμ˜ μžμ‹μœΌλ‘œλŠ” a μš”μ†Œλ‚˜ button κ³Ό 같이 μ‚¬μš©μžμ™€ μΈν„°λ ‰μ…˜μ΄ κ°€λŠ₯ν•œ μš”μ†Œλ₯Ό μžμ‹μœΌλ‘œ 두지 μ•ŠκΈ° λ•Œλ¬Έμ— μ£Όμ˜κ°€ ν•„μš”ν•©λ‹ˆλ‹€.
πŸ’‘
Internet Explorer λŠ” download 속성을 μ§€μ›ν•˜μ§€ μ•ŠμŠ΅λ‹ˆλ‹€.
<a href="https://www.naver.com">click</a> <a href="https://www.naver.com" target="_blank">click</a> <a href="./index.html">click</a> <a href="#three">click</a> <!-- 해쉬 링크 --> <a href="./index.html" download>click</a> <a href="./hello.hwp">hwp click</a> <a href="./hello.hwp" download="a.hwp">hwp download click</a> <a href="./hello.pdf">pdf click</a> <a href="./hello.pdf" download="a.pdf">pdf download click</a>
Β 

<b>, <strong>

<b> νƒœκ·ΈλŠ” ꡡ은 글꼴을 ν‘œν˜„ν•˜κ³  싢을 λ•Œ μ‚¬μš©ν•©λ‹ˆλ‹€. 별 λ‹€λ₯Έ μ˜λ―ΈλŠ” μ—†μœΌλ©° 였직 ν…μŠ€νŠΈλ₯Ό ꡡ은 κΈ€μ”¨λ‘œ ν‘œν˜„ν•˜κΈ° μœ„ν•œ μš©λ„μ΄κΈ° λ•Œλ¬Έμ— 더 이상 μ‚¬μš©ν•˜μ§€ μ•ŠλŠ” μš”μ†Œμž…λ‹ˆλ‹€. <strong> νƒœκ·ΈλŠ” ꡡ은 글꼴에 μ€‘μš”λ„λ₯Ό 더해 κ°•μ‘°ν•  λ•Œ μ‚¬μš©ν•©λ‹ˆλ‹€. μ€‘μš”λ„λ₯Ό 더 κ°•μ‘°ν•˜κ³  싢을 λ•Œμ—λŠ” strong을 μ€‘μ²©ν•˜κΈ°λ„ ν•©λ‹ˆλ‹€.
<p> <strong>hello</strong> adipisicing <b>elit</b>. </p>
Β 

<i>, <em>

<i> νƒœκ·ΈλŠ” κΈ°μšΈμž„ 글꼴을 λ‚˜νƒ€λƒ…λ‹ˆλ‹€. HTML5μ—μ„œλŠ” μ „λ¬Έ μš©μ–΄, λ¬Έλ‹¨μ—μ„œ μ£Ό 언어와 λ‹€λ₯Έ μ–Έμ–΄λ‘œ ν‘œν˜„λœ λΆ€λΆ„(μ£Ό μ–Έμ–΄κ°€ ν•œκΈ€μ΄μ§€λ§Œ μ˜μ–΄λ‘œ ν‘œκΈ°λ˜μ—ˆμ„ 경우), μ†Œμ„€μ΄λΌλ©΄ λ“±μž₯인물의 생각이 ν‘œκΈ°λ˜μ–΄ μžˆλŠ” λΆ€λΆ„ λ“± μ–΄λ–€ 이유둜 μ£Όμœ„μ™€ ꡬ뢄해야 ν•˜λŠ” 뢀뢄을 ν‘œν˜„ν•˜κΈ° μœ„ν•΄ μ‚¬μš©ν•©λ‹ˆλ‹€. <em> νƒœκ·ΈλŠ” 같은 κΈ°μšΈμž„ κΈ€κΌ΄λ‘œ ν‘œν˜„λ˜μ§€λ§Œ κ°•μ‘°μ˜ μ˜λ―Έκ°€ μžˆμŠ΅λ‹ˆλ‹€.
<p>μ‹œμž₯μ•ˆμ€ μ‚¬λžŒλ“€μ˜ ν™œκΈ°λ‘œ 가득차 μžˆμ—ˆλ‹€.</p> <p> 상인 : 이 μƒν’ˆμ€ ν˜„μž¬ <em>30%</em> ν• μΈμ€‘μž…λ‹ˆλ‹€! λ‚˜ : μ•„ν•˜ κ·Έλ ‡κ΅°μš”! <i> '흠.. μ™œ ν•˜ν•„ μ§€κΈˆ ν• μΈν•˜λŠ”κ±ΈκΉŒ?!' </i> μ’€ 더 κ΅¬κ²½ν•˜κ³  μ˜¬κ²Œμš”! </p> <p>λ‚˜λŠ” μƒμΈμ˜ μ˜λ„λ₯Ό μ˜μ‹¬ν•  수 밖에 μ—†μ—ˆλ‹€.</p>
Β 

<dfn>

ν˜„μž¬ λ¬Έλ§₯μ—μ„œ μ •μ˜ν•˜κ³  μžˆλŠ” μš©μ–΄λ₯Ό λ‚˜νƒ€λƒ…λ‹ˆλ‹€. dfn의 κ°€μž₯ κ°€κΉŒμš΄ λΆ€λͺ¨κ°€ <p> ν˜Ήμ€ <dt><dd> 쌍, <section> μš”μ†ŒμΌ 경우 κ·Έ 컨텐츠λ₯Ό dfn의 μ •μ˜μ— λŒ€ν•œ μ„€λͺ…μœΌλ‘œ κ°„μ£Όν•©λ‹ˆλ‹€. λ¬Έμ„œμ—μ„œ 졜초둜 λ‚˜νƒ€λ‚¬μ„ λ•Œ μ‚¬μš©ν•©λ‹ˆλ‹€.
<dl> <dt>WWW</dt> <dd> <dfn>WWW</dfn>λŠ” 인터넷에 μ—°κ²°λœ 컴퓨터λ₯Ό 톡해 μ‚¬λžŒλ“€μ΄ 정보λ₯Ό κ³΅μœ ν•  수 μžˆλŠ” μ „ 세계적인 정보 곡간을 λ§ν•œλ‹€. - μœ„ν‚€λ°±κ³Ό </dd> </dl>
Β 

<abbr>

<abbr> νƒœκ·ΈλŠ” 쀀말, μ•½μžλ₯Ό λ‚˜νƒ€λ‚΄κ³  싢을 λ•Œ μ‚¬μš©ν•©λ‹ˆλ‹€. 보톡은 ν™€λ‘œ 쓰이고 dfn νƒœκ·Έλ‘œ 으둜 감싸주기도 ν•©λ‹ˆλ‹€.
<dl> <dt>WWW</dt> <dd> <dfn><abbr title="World Wide Web">WWW</abbr></dfn>λŠ” 인터넷에 μ—°κ²°λœ 컴퓨터λ₯Ό 톡해 μ‚¬λžŒλ“€μ΄ 정보λ₯Ό κ³΅μœ ν•  수 μžˆλŠ” μ „ 세계적인 정보 곡간을 λ§ν•œλ‹€. - μœ„ν‚€λ°±κ³Ό </dd> </dl>
Β 

<sup>, <sub>

<sup> νƒœκ·ΈλŠ” μœ—μ²¨μž, <sub> νƒœκ·ΈλŠ” μ•„λž«μ²¨μžλ₯Ό λ‚˜νƒ€λƒ…λ‹ˆλ‹€. μž‘μ€ κΈ€μžλ₯Ό ν‘œν˜„ν•˜λŠ” μš©λ„λ‘œλŠ” μ‚¬μš©ν•˜μ§€ μ•ŠμœΌλ©° ν™”ν•™κΈ°ν˜Έλ‚˜ μˆ˜ν•™κ³΅μ‹ λ“± 첨자 기호λ₯Ό μ΄μš©ν•΄μ•Ό ν•˜λŠ” κ³³μ—μ„œλ§Œ μ‚¬μš©ν•©λ‹ˆλ‹€.
<p>H<sub>2</sub>0</p> <p>x<sup>2</sup>=4</p>
Β 

<span>

  • 별닀λ₯Έ 의미 없이 보톡 쀄 λ°”κΏˆ 없이 μ˜μ—­μ„ λ¬ΆλŠ” μš©λ„λ‘œ μ‚¬μš©ν•©λ‹ˆλ‹€.
  • μ—¬λŸ¬ μš”μ†Œλ₯Ό λ¬Άμ–΄ μ»¨νŠΈλ‘€ν•˜κΈ° μœ„ν•œ μ˜μ—­μœΌλ‘œ idλ₯Ό μ£Όκ±°λ‚˜ 클래슀λ₯Ό μ‚¬μš©ν•˜κΈ°λ„ ν•©λ‹ˆλ‹€.
  • div와 λ§ˆμ°¬κ°€μ§€λ‘œ μ΅œν›„ μˆ˜λ‹¨μœΌλ‘œ μ‚¬μš©ν•˜μ„Έμš”.
...μ€‘λž΅... <style> #λͺ…μ–Έ { color:red; } </style> ...μ€‘λž΅... <p><span id="λͺ…μ–Έ">제발 κ·Έλ§Œν•΄.. μ΄λŸ¬λ‹€ λ‹€~~ μ£½μ–΄!</span>라고 μ˜€μΌλ‚¨μ΄ μ†Œλ¦¬μ³€μŠ΅λ‹ˆλ‹€.<p>
Β 

μ†ŒμŠ€μ½”λ“œ

<!DOCTYPE html> <html> <head> <title>Document</title> </head> <body> <!-- 1. μ‹œλ©˜ν‹±ν•œ HTML κ°•μ‘°(기계가 이해할 수 μžˆλŠ” μ–Έμ–΄, SEO, μœ μ§€λ³΄μˆ˜, ν˜‘μ—… λ“±) 2. HTML Living Standard --> <h1>hello world</h1> <h2>hello world</h2> <h3>hello world</h3> <h4>hello world</h4> <h5>hello world</h5> <h6>hello world</h6> <p>H<sub>2</sub>0</p> <p>x<sup>2</sup>=4</p> <p> <!-- 곡백병합 --> Lorem ipsum <br> <br> <br> dolor sit amet <a href="https://www.naver.com">click</a> <a href="https://www.naver.com" target="_blank">click</a> <a href="./test.html">click</a> <a href="#move">click</a> <a href="./test.png" download>click</a> <strong>hello</strong> adipisicing <b>elit</b>. Quae <em>quisquam </em> aperiam, <i> autem </i>, excepturi <mark> corrupti </mark> architecto facilis saepe voluptatum, sit nulla quia voluptate at laudantium cupiditate iusto minima tempore consequatur! </p> <hr> <p>Lorem, ipsum dolor sit amet consectetur adipisicing elit. Ratione accusantium inventore, quia, nisi natus necessitatibus, delectus consequatur eum vitae architecto numquam esse quae quasi consectetur debitis voluptatem nulla. Vero, consequatur?</p> <hr> <p>Lorem, ipsum dolor sit amet consectetur adipisicing elit. Ratione accusantium inventore, quia, nisi natus necessitatibus, delectus consequatur eum vitae architecto numquam esse quae quasi consectetur debitis voluptatem nulla. Vero, consequatur?</p> <p id="move">Lorem, ipsum dolor sit amet consectetur adipisicing elit. Ratione accusantium inventore, quia, nisi natus necessitatibus, delectus consequatur eum vitae architecto numquam esse quae quasi consectetur debitis voluptatem nulla. Vero, consequatur?</p> <!-- abbr : 쀀말 ν‘œν˜„(NASA) kbd : ν‚€λ³΄λ“œ pre : μžˆλŠ” κ·ΈλŒ€λ‘œ code : μ½”λ“œλΈ”λ‘ cite : 인용(qλŠ” 인용ꡬ, citeλŠ” μΈμš©λΈ”λ‘) --> <!-- μ°Έκ³ λ¬Έμ„œ 1 : https://developer.mozilla.org/ko/docs/Web/HTML/Element --> <!-- μ°Έκ³ λ¬Έμ„œ 2 : html.spec.whatwg.org, multipage --> </body> </html>
Β