css去掉IE6下的連結虛線框樣本

來源:互聯網
上載者:User

一般去掉虛線框可以用

a,a:focus,a:active{outline:none;}

但IE6並不支援上面寫法,來試試下面方法

在IE6下,單擊超連結後會出現一個虛線框,有時候不需要這個選線框,去掉的方法是加上hidefocus屬性,如:

<a id="test" href="#" hidefocus="true">去掉虛線框</a>

想要通過JS去掉的話,將hidefocus寫成hideFocus,如:

var a = document.getElementById("test");
a.hideFocus = true;

注意:其實小編覺得沒必在管這個ie6串連虛線框了,因為目前ie6瀏覽器非常的少了。

相關文章

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.