Opera浏览器:悬停怪异

时间:2010-06-24 16:06:30

标签: html css opera

过去几天我一直在开发一个网站,并且除了Opera之外,所有主流浏览器都能正常运行。由于某些未知原因,当我退出下拉导航时导航不会还原为display:none;

如果有一些我不知道的伎俩请赐教。

问题网址:http://demo.ivannovak.com/iocaste/index.html

同样,FF,Chrome,Safari和IE7 +的一切都很好。这个问题是Opera特有的。

相关的HTML:

            <ul id="navigation">
                <li class="active"><a href="index.html">Home</a></li>
                <li><a href="about.html">About</a></li>
                <li>
                    <a href="page.html">Example Set</a>
                    <ul>
                        <li><a href="full-width.html">Full-Width Page</a></li>
                        <li><a href="html-test.html">HTML Test</a></li>
                        <li><a href="page.html">Normal Page</a></li>
                        <li>
                            <a href="page.html">GrandChild Nav</a>
                            <ul>
                                <li><a href="page.html">Normal Page</a></li>
                                <li><a href="page.html">Normal Page</a></li>
                                <li><a href="page.html">Normal Page</a></li>
                            </ul>
                        </li>
                        <li><a href="contact.html">Normal Page</a></li>
                    </ul>
                </li>
                <li><a href="blog.html">Blog</a></li>
                <li><a href="portfolio.html">Portfolio</a></li>
                <li><a href="contact.html">Contact</a></li>
            </ul><!-- #navigation -->

相关的CSS:

#navigation {
    float:right;
    position:relative;
    top:35px;
    z-index:10;
    margin-right:10px;
    list-style: none;
}

#navigation li {
    float:left;
    position:relative;
    margin:0;
    padding:0;
}

#navigation li.active > a,
#navigation li a:hover {
    color:#e5e5e5;
}

#navigation li a {
    color:#b2b2b2;
    text-decoration:none;
    padding:5px 12px;
}

#navigation li ul {
    display:none;
    position:absolute;
    text-align:center;
    z-index:3;
    left:50%;
    margin:0 0 0 -104px;
    padding-bottom:10px;
    top:100%;
    list-style: none;
}

#navigation li:hover ul {
    display:block;
}

#navigation li ul li {
    width:178px;
    text-align:center;
    padding:0 15px;
    float:none;
}

#navigation > li > ul > li:first-child {
    background:url(../img/child_nav_top.png) no-repeat 50% 0 transparent;
    padding-top:20px;
}

#navigation > li > ul > li {
    background:url(../img/child_nav_repeat.png) repeat-y 50% 0 transparent;
}

#navigation > li > ul > li:last-child {
    background:url(../img/child_nav_bottom.png) no-repeat 50% 100% transparent;
    padding-bottom:20px!important;
}

#navigation li.lastChild {


/*  IE 8 is dumb */
    background:url(../img/child_nav_bottom.png) no-repeat 50% 100% transparent;
    padding-bottom:20px!important;
}

#navigation li ul li ul {
    position:absolute;
    display:none!important;
    z-index:4;
    left:278px;
    top:-15px;
}

#navigation li ul li:hover ul {
    display:block!important;
}

#navigation li ul li ul li {
    float:none;
    width:119px;
    text-align:center;
    padding:0 8px 0 15px;
}

#navigation > li > ul > li > ul > li:first-child {
    background:url(../img/grandChild_nav_top.png) no-repeat 50% 0 transparent;
    padding-top:15px;
}

#navigation > li > ul > li > ul > li {
    background:url(../img/grandChild_nav_repeat.png) repeat-y 50% 0 transparent;
}

#navigation > li > ul > li > ul > li:last-child {
    background:url(../img/grandChild_nav_bottom.png) no-repeat 50% 100% transparent;
    padding-bottom:20px;
}

#navigation li.lastGrandChild {
    background:url(../img/grandChild_nav_bottom.png) no-repeat 50% 100% transparent;
    padding-bottom:20px;
}

1 个答案:

答案 0 :(得分:0)

似乎这是一个重绘错误,已在以后的版本中得到修复。