作者热门文章
- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
open new html file 最佳答案 您只需将链接的目标设置为空-6ren">
单击标签时,我希望它在另一个选项卡中打开另一个 .html 文件(例如可以称为discuss.html)。
<!DOCTYPE html>
<html>
<head>
<body>
<a href="<!--I don't know what to put here pls help-->">open new html file</a>
</body>
</head>
</html>
最佳答案
您只需将链接的目标设置为空白即可。见下文:
<html>
<head>
<body>
<a href="discussions.html" target="_blank">DISCUSSIONS</a>
</body>
</head>
</html>
关于html - onclick <a> 标签,在新选项卡中打开另一个 html 文件,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/64299626/
我是一名优秀的程序员,十分优秀!