# URL

[JS](../../js) ⟩ [browser](..) ⟩ [web API]() ⟩ URL

{% tabs %}
{% tab title="⭐️ 重點" %}
```
+-------------------+---------------------+
|        Part       |       Data          |
+-------------------+---------------------+
|  Scheme           | https               |
|  User             | bob                 |
|  Password         | bobby               |
|  Host             | www.lunatech.com    |
|  Port             | 8080                |
|  Path             | /file;p=1           |
|  Path parameter   | p=1                 |
|  Query            | q=2                 |
|  Fragment         | third               |
+-------------------+---------------------+

https://bob:bobby@www.lunatech.com:8080/file;p=1?q=2#third
\___/   \_/ \___/ \______________/ \__/\_______/ \_/ \___/
  |      |    |          |          |      | \_/  |    |
Scheme User Password    Host       Port  Path |   | Fragment
        \_____________________________/       | Query
                       |               Path parameter
                    Authority
```
{% endtab %}

{% tab title="🗣 討論" %}
* SOF ⟩ [URL encoding the space character: + or %20?](https://stackoverflow.com/questions/1634271/url-encoding-the-space-character-or-20)
{% endtab %}

{% tab title="📘 手冊" %}
* [URL](https://developer.mozilla.org/en-US/docs/Web/API/URL) - Uniform Resource Locator
* [term: URL](https://developer.mozilla.org/en-US/docs/Glossary/URL)
* [What is a URL?](https://developer.mozilla.org/en-US/docs/Learn/Common_questions/What_is_a_URL)
* [Data URLs](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URLs)
{% endtab %}

{% tab title="📗 參考" %}
* [ ] JavaScript: The Definitive Guide (11.9 URL APIs)
* [ ] MDN ⟩&#x20;
  * [ ] [What is a URL?](https://developer.mozilla.org/en-US/docs/Learn/Common_questions/What_is_a_URL)
  * [ ] [Data URLs](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URLs)
{% endtab %}
{% endtabs %}
