如何使用一个锚标记打开多个链接
16lz
2021-01-22
So here's a simple but interesting question, how can I open multiple links using single <a>
element?
这里有一个简单但有趣的问题,如何使用single 元素打开多个链接?
Using this only opens the first href
使用这个只打开第一个href
<a href="http://www.google.com" href="http://www.yahoo.com" target="_blank">Click Here</a>
1 个解决方案
#1
37
You can certainly try this
你当然可以试试。
Demo
演示
<a href="http://www.microsoft.com" target="_blank" onclick="window.open('http://www.google.com'); window.open('http://www.yahoo.com');">Click Here</a>
更多相关文章
- html css伪元素标签(二)灵活
- 如何使用Watir访问自定义属性的元素?
- HTML5按钮元素新属性formaction,formenctype等简介
- HTML高级标签之窗口分帧(前台界面演示)
- 如何使用jQuery在我的网站演示中自动填写表单,好像真人正在打字?
- 禁用div中的所有表单元素
- 怎么动态设置html的canvas元素的尺寸?
- JQuery基于元素的高度添加类
- 单个元素html上的多个类