"Go" link pseudo-Class (: hover) CSS background picture has flashing bug

Source: Internet
Author: User

Source: http://www.css88.com/archives/744

-------------------------------------------------------------------------------------------------

IE6 under the link pseudo-class (: hover) CSS background image has a flashing bug, the main reason IE will once again request this picture, or that the picture is not cached.

For example:

CSS Code
    1. a:hover{background:URL (imagepath)}

Common solutions:

Add the following IE6 private code at the bottom of the page to let IE6 cache the CSS background image locally so that the a:hover will not be re-requested to load the background image at the time of IE6.

xml/html Code
    1. <!–[if IE 6]>
    2. <script type= "text/javascript">
    3. Document.execcommand ("Backgroundimagecache", false, true);
    4. </Script>
    5. <! [endif]–>

Or

xml/html Code
    1. <!–[if IE 6]>
    2. <script type=text/javascript>
    3. try {
    4. Document.execcommand ("Backgroundimagecache", false, true);
    5. } catch (Err) {}
    6. </Script>
    7. <! [endif]–>

"Go" link pseudo-Class (: hover) CSS background picture has flashing bug

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

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.