HTML中<a>标签跳转新页面的各种方式

来源:互联网 发布:打不开网络和共享中心 编辑:程序博客网 时间:2024/06/04 18:34

原文地址:http://blog.csdn.net/wild46cat/article/details/51669189


  1. <
    a href="http://www.baidu.com" target="_blank">百度_blank</a><br/>  
  2.     <a href="http://www.baidu.com" target="_self">百度_self</a><br/>  
  3.     <a href="javascript:void(0);" onclick="window.location.href='http://www.baidu.com'" target="_blank">百度1_click</a><br/>  
  4.     <a href="javascript:void(0);" onclick="window.open('http://www.baidu.com','_self');" target="_blank">百度_self_click</a><br/>  
  5.     <a href="javascript:void(0);" onclick="window.open('http://www.baidu.com','_blank');" target="_blank">百度_blank_click</a><br/>  


原创粉丝点击