docs(10_Wiki): W3Schools 위키화 — HTML/CSS/JavaScript(core)
W3Schools 튜토리얼을 P-Reinforce v3.1 포맷으로 위키화(영어 본문, 한/영 섹션 헤더). - Topic_HTML: 59문서 (튜토리얼+예제, 레퍼런스/메타 제외) - Topic_CSS: 190문서 (메인 + Advanced/Flexbox/Grid/RWD 전체) - Topic_JavaScript: 120문서 (코어 언어; Temporal/DOM상세/BOM/WebAPI/AJAX/jQuery/Graphics 등은 후속) 각 폴더 00_INDEX.md(MOC) 포함. 코드 verbatim, 미확인분은 "Not found in source" 표기. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,143 @@
|
||||
---
|
||||
id: html-entities
|
||||
title: "HTML Entities"
|
||||
category: "Frontend"
|
||||
status: "draft"
|
||||
verification_status: "conceptual"
|
||||
canonical_id: ""
|
||||
aliases: ["character entities", "reserved characters", "non-breaking space", "nbsp", "entity name", "entity number", "diacritical marks"]
|
||||
duplicate_of: ""
|
||||
source_trust_level: "B"
|
||||
confidence_score: 0.90
|
||||
created_at: 2026-06-23
|
||||
updated_at: 2026-06-23
|
||||
review_reason: ""
|
||||
merge_history: []
|
||||
tags: ["html", "web", "frontend", "w3schools", "entities", "characters"]
|
||||
raw_sources: ["https://www.w3schools.com/html/html_entities.asp"]
|
||||
applied_in: []
|
||||
github_commit: ""
|
||||
---
|
||||
|
||||
# [[HTML Entities]]
|
||||
|
||||
## 🎯 한 줄 통찰 (One-line insight)
|
||||
Reserved characters in HTML must be replaced with entities — written as an entity name (`&name;`) or an entity number (`&#number;`) — so the browser does not confuse them with tags. [S1]
|
||||
|
||||
## 🧠 핵심 개념 (Core concepts)
|
||||
- **Reserved characters need entities** — characters like `<` and `>` are reserved; if used directly in text, the browser might mix them up with tags. [S1]
|
||||
- **Two entity forms** — entity names (`&entity_name;`) or entity numbers (`&#entity_number;`) can both display reserved characters. [S1]
|
||||
- **Names are easier** — entity names are easier to remember than entity numbers. [S1]
|
||||
- **Names are case sensitive** — entity names must use the correct case. [S1]
|
||||
- **Non-breaking space (` `)** — a space that will not break into a new line and prevents the browser from truncating consecutive spaces. [S1]
|
||||
- **Combining diacritical marks** — marks can combine with alphanumeric characters to produce characters not present in the page's encoding. [S1]
|
||||
|
||||
## 🧩 추출된 패턴 (Extracted patterns)
|
||||
- **Less-than** — `<` or `<` displays `<`. [S1]
|
||||
- **Greater-than** — `>` or `>` displays `>`. [S1]
|
||||
- **Ampersand** — `&` displays `&`. [S1]
|
||||
- **Non-breaking space** — ` ` keeps two words on the same line (e.g. `10 km/h`, `10 PM`) and adds real spaces. [S1]
|
||||
- **Combining mark** — base char + mark number, e.g. `à` → `à`. [S1]
|
||||
|
||||
## 📖 세부 내용 (Details)
|
||||
**Reserved characters**
|
||||
Some characters are reserved in HTML. If you use the less-than (`<`) or greater-than (`>`) signs in your HTML text, the browser might mix them with tags. Entity names or entity numbers can be used to display reserved HTML characters. [S1]
|
||||
- `<` (less than) = `<`
|
||||
- `>` (greater than) = `>`
|
||||
|
||||
**Entity syntax**
|
||||
An entity is written either as a name or as a number: [S1]
|
||||
```text
|
||||
&entity_name;
|
||||
&#entity_number;
|
||||
```
|
||||
For example, to display a less-than sign (`<`) we must write `<` or `<`. Entity names are easier to remember than entity numbers. [S1]
|
||||
|
||||
> Note: Entity names are case sensitive. [S1]
|
||||
|
||||
**Non-breaking space**
|
||||
A commonly used HTML entity is the non-breaking space: ` `. A non-breaking space is a space that will not break into a new line. Two words separated by a non-breaking space will stick together (not break into a new line). This is handy when breaking the words might be disruptive, for example: [S1]
|
||||
- `§ 10`
|
||||
- `10 km/h`
|
||||
- `10 PM`
|
||||
|
||||
Another common use of the non-breaking space is to prevent browsers from truncating spaces in HTML pages. If you write 10 spaces in your text, the browser will remove 9 of them; to add real spaces to your text, you can use the ` ` character entity. The non-breaking hyphen (`‑`) is used to define a hyphen character (`‑`) that does not break into a new line. [S1]
|
||||
|
||||
**Some useful HTML character entities**
|
||||
|
||||
| Result | Description | Name | Number |
|
||||
|---|---|---|---|
|
||||
| (space) | non-breaking space | ` ` | ` ` |
|
||||
| < | less than | `<` | `<` |
|
||||
| > | greater than | `>` | `>` |
|
||||
| & | ampersand | `&` | `&` |
|
||||
| " | double quotation mark | `"` | `"` |
|
||||
| ' | single quotation mark | `'` | `'` |
|
||||
| ¢ | cent | `¢` | `¢` |
|
||||
| £ | pound | `£` | `£` |
|
||||
| ¥ | yen | `¥` | `¥` |
|
||||
| € | euro | `€` | `€` |
|
||||
| © | copyright | `©` | `©` |
|
||||
| ® | registered trademark | `®` | `®` |
|
||||
| ™ | trademark | `™` | `™` |
|
||||
|
||||
[S1]
|
||||
|
||||
**Combining diacritical marks**
|
||||
A diacritical mark is a "glyph" added to a letter. Some diacritical marks, like grave ( ̀) and acute ( ́), are called accents. Diacritical marks can be used in combination with alphanumeric characters to produce a character that is not present in the character set (encoding) used in the page. [S1]
|
||||
|
||||
| Mark | Character | Construct | Result |
|
||||
|---|---|---|---|
|
||||
| ̀ | a | `à` | à |
|
||||
| ́ | a | `á` | á |
|
||||
| ̂ | a | `â` | â |
|
||||
| ̃ | a | `ã` | ã |
|
||||
| ̀ | O | `Ò` | Ò |
|
||||
| ́ | O | `Ó` | Ó |
|
||||
| ̂ | O | `Ô` | Ô |
|
||||
| ̃ | O | `Õ` | Õ |
|
||||
|
||||
[S1]
|
||||
|
||||
## 🛠️ 적용 사례 (Applied in summary)
|
||||
The reserved-character substitutions (`<`, `>`, `&`), the ` ` usage examples (`10 km/h`, `10 PM`, preserving spaces), and the combining-mark constructs (`à` → à) are the canonical applied examples. No external project/commit applications found in the source.
|
||||
|
||||
## 💻 코드 패턴 (Code patterns)
|
||||
Display a literal less-than sign:
|
||||
```html
|
||||
<
|
||||
<
|
||||
```
|
||||
Keep two words on the same line:
|
||||
```html
|
||||
10 km/h
|
||||
```
|
||||
Combine a base character with a diacritical mark:
|
||||
```html
|
||||
à <!-- renders as à -->
|
||||
```
|
||||
|
||||
## ⚖️ 비교 및 선택 기준 (Comparison & decision criteria)
|
||||
- **Entity name (`<`)** — easier to remember; case sensitive. [S1]
|
||||
- **Entity number (`<`)** — numeric alternative producing the same character. [S1]
|
||||
|
||||
## ⚖️ 모순 및 업데이트 (Contradictions & updates)
|
||||
No contradictions found in the source.
|
||||
|
||||
## ✅ 검증 상태 및 신뢰도
|
||||
- **상태:** draft
|
||||
- **검증 단계:** conceptual (실제 적용 사례 발견 시 applied/validated로 승격 가능)
|
||||
- **출처 신뢰도:** B (W3Schools — widely used educational reference, not a primary standards body)
|
||||
- **신뢰 점수:** 0.90
|
||||
- **중복 검사 결과:** 신규 생성 (New discovery)
|
||||
|
||||
## 🔗 지식 그래프 (Knowledge Graph)
|
||||
- **상위/루트:** [[HTML Tutorial]]
|
||||
- **관련 개념:** [[HTML Symbols]], [[HTML Charset]], [[HTML Formatting]], [[HTML Introduction]]
|
||||
- **참조 맥락:** Referenced whenever reserved characters, special symbols, real spaces, or accented characters must be displayed safely in HTML text.
|
||||
|
||||
## 📚 출처 (Sources)
|
||||
- [S1] W3Schools — HTML Entities — https://www.w3schools.com/html/html_entities.asp
|
||||
|
||||
## 📝 변경 이력 (Change history)
|
||||
- 2026-06-23: Initial draft synthesized from the W3Schools "HTML Entities" page (Astra wiki-curation, P-Reinforce v3.1 format).
|
||||
Reference in New Issue
Block a user