Attribute value of the target tag in HTML

Attribute value of the target tag in HTML

There are four different target tag attribute values

//跳转到新的文档页面,也就是打开新的目标文档
<a target = "_blank"></a>

//在当前页面进行跳转,是 a 标签的默认值
<a target = "_self"></a>

//以文档在父窗口上的方式跳转,如果父窗口是window对象的话,那么效果和_self相同
<a target = "_parent"></a>

//能够跳转出包含这个超链接的窗口
<a target = "_top"></a>

You can also set the current document object all a way to jump labels

Only you need to add the base label head label the current document object

<html>
	//设置了当前文档中所有的 a 标签的跳转方式为跳转到新的页面
	<base target = "_blank">
</html>
<body>
</body>

Guess you like

Origin blog.csdn.net/qq_36949892/article/details/90449950
Recommended