代码改变世界

去掉链接的边框

2013-01-15 09:27  yangpan  阅读(174)  评论(0编辑  收藏  举报

1.ie下添加属性hidefocus="true"

2.ff等浏览器 outline:none;

3将以下代码保存为link.htc文件

<public:attachevent="onfocus"onevent="hscfsy()"/>

<scripttype="text/javascript">
function hscfsy(){this.blur();}
</script>

链接样式中加入:

a { behavior:url(link.htc);}