9609c04755
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>
123 lines
5.4 KiB
Markdown
123 lines
5.4 KiB
Markdown
---
|
|
id: html-url-encode
|
|
title: "HTML URL Encode"
|
|
category: "Frontend"
|
|
status: "draft"
|
|
verification_status: "conceptual"
|
|
canonical_id: ""
|
|
aliases: ["URL encoding", "percent encoding", "URL", "Uniform Resource Locator", "URL schemes", "ASCII URL encoding"]
|
|
duplicate_of: ""
|
|
source_trust_level: "B"
|
|
confidence_score: 0.88
|
|
created_at: 2026-06-23
|
|
updated_at: 2026-06-23
|
|
review_reason: ""
|
|
merge_history: []
|
|
tags: ["html", "web", "frontend", "url", "encoding", "w3schools"]
|
|
raw_sources: ["https://www.w3schools.com/html/html_urlencode.asp"]
|
|
applied_in: []
|
|
github_commit: ""
|
|
---
|
|
|
|
# [[HTML URL Encode]]
|
|
|
|
## 🎯 한 줄 통찰 (One-line insight)
|
|
A URL (Uniform Resource Locator) is a web address that can only be sent over the Internet using the ASCII character set, so non-ASCII characters are **URL-encoded** — replaced by a `%` followed by hexadecimal digits (and spaces by `+` or `%20`). [S1]
|
|
|
|
## 🧠 핵심 개념 (Core concepts)
|
|
- **URL** — a Uniform Resource Locator is a web address used to request pages from web servers. [S1]
|
|
- **URL syntax** — a URL follows the structure `scheme://prefix.domain:port/path/filename`. [S1]
|
|
- **Schemes** — the type of Internet service (http, https, ftp, file). [S1]
|
|
- **Why encoding is needed** — URLs can only be sent over the Internet using the ASCII character set; characters outside ASCII must be encoded. [S1]
|
|
- **Encoding scheme** — non-ASCII characters become `%` + hexadecimal digits; spaces become `+` or `%20`. [S1]
|
|
- **Default charset** — the default character set in HTML5 is UTF-8. [S1]
|
|
|
|
## 🧩 추출된 패턴 (Extracted patterns)
|
|
- **URL syntax pattern** — `scheme://prefix.domain:port/path/filename`. [S1]
|
|
- **Percent-encoding pattern** — `%HH` where `HH` is the hexadecimal value of the byte (e.g. `%20` for a space). [S1]
|
|
- **Space encoding** — `+` or `%20`. [S1]
|
|
- **Multi-byte UTF-8 encoding** — one character may expand to several `%HH` pairs (e.g. © → `%C2%A9` in UTF-8). [S1]
|
|
|
|
## 📖 세부 내용 (Details)
|
|
**URL — Uniform Resource Locator**
|
|
A URL is a web address used to request pages from web servers. The basic syntax is: [S1]
|
|
```
|
|
scheme://prefix.domain:port/path/filename
|
|
```
|
|
|
|
Syntax components: [S1]
|
|
|
|
| Component | Meaning |
|
|
|---|---|
|
|
| `scheme` | The type of Internet service (http or https are most common) |
|
|
| `prefix` | The domain prefix (default for http is `www`) |
|
|
| `domain` | The Internet domain name (e.g. `w3schools.com`) |
|
|
| `port` | The port number at the host (default for http is `80`) |
|
|
| `path` | The path at the server (root directory if omitted) |
|
|
| `filename` | The name of the document or resource |
|
|
|
|
**Common URL Schemes** [S1]
|
|
|
|
| Scheme | Short for | Used for |
|
|
|---|---|---|
|
|
| http | HyperText Transfer Protocol | Common web pages. Not encrypted |
|
|
| https | Secure HyperText Transfer Protocol | Secure web pages. Encrypted |
|
|
| ftp | File Transfer Protocol | Downloading or uploading files |
|
|
| file | — | A file on your computer |
|
|
|
|
**URL Encoding**
|
|
URLs can only be sent over the Internet using the ASCII character set. If a URL contains characters outside the ASCII set, it has to be converted. URL encoding replaces non-ASCII characters with a `%` followed by hexadecimal digits. URLs cannot contain spaces; a space is encoded with `+` or `%20`. The default character set in HTML5 is UTF-8. [S1]
|
|
|
|
**ASCII Encoding Examples** [S1]
|
|
|
|
| Character | From Windows-1252 | From UTF-8 |
|
|
|---|---|---|
|
|
| € | %80 | %E2%82%AC |
|
|
| £ | %A3 | %C2%A3 |
|
|
| © | %A9 | %C2%A9 |
|
|
| ® | %AE | %C2%AE |
|
|
| À | %C0 | %C3%80 |
|
|
| Á | %C1 | %C3%81 |
|
|
| Â | %C2 | %C3%82 |
|
|
| Ã | %C3 | %C3%83 |
|
|
| Ä | %C4 | %C3%84 |
|
|
| Å | %C5 | %C3%85 |
|
|
|
|
(Ten character mappings shown; the page references a complete URL encoding reference guide elsewhere.) [S1]
|
|
|
|
## 🛠️ 적용 사례 (Applied in summary)
|
|
The ASCII encoding examples above are the canonical applied case: converting characters such as © to `%C2%A9` (UTF-8) so they can travel safely inside a URL. No external project/commit applications found in the source.
|
|
|
|
## 💻 코드 패턴 (Code patterns)
|
|
URL structure (syntax template):
|
|
```
|
|
scheme://prefix.domain:port/path/filename
|
|
```
|
|
Percent-encoded values (examples):
|
|
```
|
|
space -> %20 (or +)
|
|
© -> %C2%A9 (UTF-8)
|
|
€ -> %E2%82%AC (UTF-8) / %80 (Windows-1252)
|
|
```
|
|
|
|
## ⚖️ 모순 및 업데이트 (Contradictions & updates)
|
|
No contradictions found in the source. Note that the same character encodes differently depending on the source character set (e.g. € is `%80` from Windows-1252 but `%E2%82%AC` from UTF-8); HTML5's default UTF-8 governs modern encoding. [S1]
|
|
|
|
## ✅ 검증 상태 및 신뢰도
|
|
- **상태:** draft
|
|
- **검증 단계:** conceptual (실제 적용 사례 발견 시 applied/validated로 승격 가능)
|
|
- **출처 신뢰도:** B (W3Schools — widely used educational reference, not a primary standards body)
|
|
- **신뢰 점수:** 0.88
|
|
- **중복 검사 결과:** 신규 생성 (New discovery)
|
|
|
|
## 🔗 지식 그래프 (Knowledge Graph)
|
|
- **상위/루트:** [[HTML Tutorial]]
|
|
- **관련 개념:** [[HTML Charsets]], [[HTML Symbols]], [[HTML Links]], [[HTML Forms]]
|
|
- **참조 맥락:** Referenced when constructing or transmitting web addresses, especially query strings and links containing special characters.
|
|
|
|
## 📚 출처 (Sources)
|
|
- [S1] W3Schools — HTML URL Encode — https://www.w3schools.com/html/html_urlencode.asp
|
|
|
|
## 📝 변경 이력 (Change history)
|
|
- 2026-06-23: Initial draft synthesized from the W3Schools "HTML URL Encode" page (Astra wiki-curation, P-Reinforce v3.1 format).
|