使用jquery跳转a标签
2015-08-06 16:11
681 查看
使用jquery跳转a标签:
<a href="..." class="popup">Hello</a>
<script>
$("a.popup").click(function(event){
event.preventDefault();
//阻止默认的点击事件
window.open(this.getAttribute('href'));
//弹出新窗口显示跳转页面
});
</script>
<a href="..." class="popup">Hello</a>
<script>
$("a.popup").click(function(event){
event.preventDefault();
//阻止默认的点击事件
window.open(this.getAttribute('href'));
//弹出新窗口显示跳转页面
});
</script>
相关文章推荐
- jquery弹窗
- jQuery读取JSON文件
- jQuery插件cycle图片变换
- jQuery插件reel3D展示
- jquery event
- jQuery中offset和position方法
- jQuery操作Class
- jQuery为元素添加样式
- jQuery的on方法绑定事件
- jQuery UI vs EasyUI
- PHP+jquery实现的三级联动
- jquery load方法用法详解
- ajaxFileUpload 报这错jQuery.handleError is not a function 博客分类: WEB前端jquery
- jQuery的选择器中的通配符[id^='code']
- jquery判断值是否存在于数组中
- jQuery mask
- PHP+jQuery+Ajax+Mysql如何实现发表心情功能
- 省市地区三级联动弹出层Jquery特效
- Jquery 判断radio,selelct,checkbox是否选中
- jquery 预览并自增 上传图片