1

I have a huge problem with a child template that I make using skeleton wp framework. the website works well on FF and chrome but (obviusly) doesn't work in IE8.

Or better it work but I have a problem with the sub menu that looks like this in IE: IE view

While it shoud look like this:

FF view

The css menu code is this:

    /* MENU DI NAVIGAZIONE
================================================== */

.band.navigation {
    background-color: #EEEFEF;

    background: -moz-linear-gradient(top,  #eeefef 0%, #dddddd 100%); /* FF3.6+ */
    background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#eeefef), color-stop(100%,#dddddd)); /* Chrome,Safari4+ */
    background: -webkit-linear-gradient(top,  #eeefef 0%,#dddddd 100%); /* Chrome10+,Safari5.1+ */
    background: -o-linear-gradient(top,  #eeefef 0%,#dddddd 100%); /* Opera 11.10+ */
    background: -ms-linear-gradient(top,  #eeefef 0%,#dddddd 100%); /* IE10+ */
    background: linear-gradient(to bottom,  #eeefef 0%,#dddddd 100%); /* W3C */
    filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#eeefef', endColorstr='#dddddd',GradientType=0 ); /* IE6-9 */
}

nav.primario ul, nav ul li {
    margin: 0;
}

nav.primario ul li {
    display: inline;
    float: left;
    position: relative;
}

nav.primario ul li a {
    display: inline-block;
    line-height: 49px;
    color: #424242;
    text-decoration: none;
    letter-spacing: 0.08em;
    /*font-weight: bold;*/
    padding: 0 14px;

    text-shadow: 0.05em 0.05em 0.1em rgba(0,0,0, 0.5);
}

nav.primario ul li a:hover{
    background-color: #afd3db;
    cursor: pointer;
    border-radius: 10px;
    color: #fff;

    background: -moz-linear-gradient(top,  #4b9bae 0%, #418697 100%); /* FF3.6+ */
    background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#4b9bae), color-stop(100%,#418697)); /* Chrome,Safari4+ */
    background: -webkit-linear-gradient(top,  #4b9bae 0%,#418697 100%); /* Chrome10+,Safari5.1+ */
    background: -o-linear-gradient(top,  #4b9bae 0%,#418697 100%); /* Opera 11.10+ */
    background: -ms-linear-gradient(top,  #4b9bae 0%,#418697 100%); /* IE10+ */
    background: linear-gradient(to bottom,  #4b9bae 0%,#418697 100%); /* W3C */
    filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#4b9bae', endColorstr='#418697',GradientType=0 ); /* IE6-9 */


    -webkit-transition: .5s ease-out;
    -moz-transition: .5s ease-out;
    -o-transition: .5s ease-out;
    -ms-transition: .5s ease-out;
    transition: .5s ease-out;
}

/*Menu a tendina per dispositivi mobili nascosto*/
nav.primario select {
    display: none;
    width: 100%;
    height: 28px;
    margin: 21px 0;
}

/*SOTTO MENU*/
nav.primario ul ul{
    -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";
    filter: alpha(opacity=0);
    opacity: 0;

    position: absolute;
    z-index: 999; /*Per farlo apparire sopra il menu*/
    background: #DDDDDD;
    width: 200%;
    min-width: 100%;
    /*Nascondere il menu se non avviene il passaggio del mouse*/
    height: 0px; 
    overflow: hidden;

    -webkit-transition: .5s ease-out;
    -moz-transition: .5s ease-out;
    -o-transition: .5s ease-out;
    -ms-transition: .5s ease-out;
    transition: .5s ease-out;

    -webkit-box-shadow: 2px 2px 2px rgba(0,0,0,0.3);
    box-shadow: 2px 2px 2px rgba(0,0,0,0.3);
}

/*Hover state al menu*/
nav.primario ul li:hover ul {
    -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=1000)";
    filter: alpha(opacity=1000);
    opacity: 10;

    height: auto;
    overflow: auto;
}

nav.primario ul ul li{
    float: none;
    display: list-item;
}

nav.primario ul ul li a{
    display: block;
    line-height: 35px;
    text-decoration: none;
}

/*fissare il colore al menu principale quando l'hover è attivo nel sottomenu*/
nav.primario ul li:hover > a {
    background-color: #afd3db;
    border-radius: 10px;
}

Please I've try anything but I can't figure out how I can make that submenu look decent on IE... Thanks a lot in advace to all the community

4

1 回答 1

2
.band.navigation { 
    background: #EEEFEF; 
    background: -moz-linear-gradient(top,  #eeefef 0%, #dddddd 100%); /* FF3.6+ */
    background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#eeefef), color-stop(100%,#dddddd)); /* Chrome,Safari4+ */
    background: -webkit-linear-gradient(top,  #eeefef 0%,#dddddd 100%); /* Chrome10+,Safari5.1+ */
    background: -o-linear-gradient(top,  #eeefef 0%,#dddddd 100%); /* Opera 11.10+ */
    background: -ms-linear-gradient(top,  #eeefef 0%,#dddddd 100%); /* IE10+ */
    background: linear-gradient(to bottom,  #eeefef 0%,#dddddd 100%); /* W3C */
}

不要使用filter:它会使 ie 渲染速度变慢,而且不值得。

这应该解决它

于 2013-03-28T11:36:41.820 回答