Skip to content

Commit 10508b4

Browse files
committed
doc: udpate docs/tags/base.md
1 parent 5faeda9 commit 10508b4

File tree

3 files changed

+58
-5
lines changed

3 files changed

+58
-5
lines changed

docs/attribute/global/accesskey.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ HTML accesskey 属性
88
具有指定访问键的两个超链接:
99

1010
```html idoc:preview
11-
<a href="https://www.w3schools.com/html/" accesskey="h">HTML</a><br>
12-
<a href="https://www.w3schools.com/css/" accesskey="c">CSS</a>
11+
<a href="https://github.com/jaywcjlove/html-tutorial" accesskey="h">HTML</a><br>
12+
<a href="https://github.com/jaywcjlove/html-tutorial" accesskey="c">CSS</a>
1313
```
1414

1515
## 定义和使用

docs/attribute/global/tabindex.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ HTML `tabindex` 属性
88
带有指定 tab 键顺序的链接:
99

1010
```html idoc:preview
11-
<a href="https://www.w3schools.com/" tabindex="2">W3Schools</a>
11+
<a href="hhttps://github.com/jaywcjlove/html-tutorialhttps://github.com/jaywcjlove/html-tutorial" tabindex="2">W3Schools</a>
1212
<a href="http://www.google.com/" tabindex="1">Google</a>
1313
<a href="http://www.microsoft.com/" tabindex="3">Microsoft</a>
1414
```

docs/tags/base.md

Lines changed: 55 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,57 @@
1-
base.md
1+
HTML \<base> 标签
22
===
33

4-
欢迎您编辑 <a target="__blank" href="https://github.com/jaywcjlove/html-tutorial/blob/master/docs/tags/base.md">docs/tags/base.md</a> 文件,共建 HTML Tutorial 文档。
4+
标记指定文档中所有相对 URL 的基本 URL 和/或目标
5+
6+
## 示例
7+
8+
为页面上的所有链接指定默认 URL 和默认目标:
9+
10+
```html idoc:preview
11+
<head>
12+
  <base href="https://github.com/jaywcjlove/html-tutorial" target="_blank">
13+
</head>
14+
15+
<body>
16+
<img src="images/stickman.gif" width="24" height="39" alt="Stickman">
17+
<a href="tags/tag_base.asp">HTML base Tag</a>
18+
</body>
19+
```
20+
21+
## 定义和用法
22+
23+
`<base>` 标记指定文档中所有相对 URL 的基本 URL 和/或目标。
24+
25+
`<base>` 标记必须具有 href 或 target 属性,或两者兼有。
26+
27+
文档中只能有一个 `<base>` 元素,并且它必须在 \<head> 元素内。
28+
29+
30+
## Browser Support
31+
32+
| Element | ![chrome][1] | ![edge][2] | ![firefox][3] | ![safari][4] | ![opera][5] |
33+
| ------- | --- | --- | --- | --- | --- |
34+
| \<base> | Yes | Yes | Yes | Yes | Yes |
35+
36+
## 属性 idoc:preview
37+
38+
| 属性 Attribute | 值 Value | 描述 Description |
39+
| ------ | ------ | ------ |
40+
| [href](att_base_href.asp) | *URL* | 指定页面中所有相对 URL 的基本 URL|
41+
| [target](att_base_target.asp) | \_blank<br/> \_parent<br/>\_self<br/>\_top | 指定页面中所有超链接和表单的默认目标|
42+
43+
44+
## 全局属性
45+
46+
`<base>` 标签支持 HTML 中的[全局属性](../reference/standardattributes.md)
47+
48+
## 事件属性
49+
50+
`<base>` 标签支持 HTML 中的[事件属性](../reference/eventattributes.md)
51+
52+
53+
[1]: ../assets/chrome.svg
54+
[2]: ../assets/edge.svg
55+
[3]: ../assets/firefox.svg
56+
[4]: ../assets/safari.svg
57+
[5]: ../assets/opera.svg

0 commit comments

Comments
 (0)