Re...
Merci Heyoan. J'ai effectué quelques modifications, surtout suivies d'après cet article :
http://www.alistapart.com/articles/horizdropdowns/
mais toujours pas d'affichage de sous-menu sous IE6...
Je me permets de vous refaire passer le code css et javascript.
CSS
/**00000000000000000000000000000000000
000 MENU 00
00000000000000000000000000000000000**/
div#toolbox {
float:right;
margin: 3px 10px 0 0 !important;
margin-top:7px;
}
div#menu {
background: url(../images/menu_bg.gif) no-repeat center;
border: 10px solid white;
width: 796px;
height: 27px;
line-height: 27px;
margin: 0;
padding: 0;
}
/* because IE 5.x sucks */
div#\menu {
width: 776px;
}
div#ulcontainer {
margin: 0 0 0 30px;
z-index: 1;
}
div#menu ul {
margin: 0;
padding: 0;
display: inline;
}
div#menu li {
margin: 0;
padding: 0px;
font-weight: bold;
background: url(../images/li_menu.gif) repeat-y 0 0;
display: block;
float: left;
}
#menu li a {
display:block;
margin-left:2px;
color: #285A8A;
padding: 0 10px;
}
div#menu li a:hover {
color: white;
background-color: #4B75A2;
}
a.menuon {
color: white ! important;
background-color: #4B75A2;
}
ul, li {
list-style-type: none;
}
#ulcontainer .submenu {
position: absolute;
text-align: left;
height: 15px;
list-style: none;
display: none;
width: 145px;
}
.submenu a {
padding: 0px 2px;
}
#ulcontainer .submenu li
{
float: none;
height: 18px;
width: 170px;
border-style: none;
border-bottom: #fff 1px solid;
background-color: #ccc;
padding-top: 0px;
padding-bottom: 3px;
vertical-align: middle;
}
#ulcontainer .submenu a:link,
#ulcontainer .submenu a:visited {
border-left: solid 1px;
display: block;
font-size: 11px;
padding-bottom: 3px;
border-color: transparent;
height: 18px;
}
/*#ulcontainer li:hover > .submenu, #ulcontainer li.over > .submenu {
z-index: 110;
display: block;
height: 18px;
} */
#ulcontainer ul li:hover > .submenu, #ulcontainer ul li.over ul{
display: block;
z-index: 500;
}
html ul.submenu li a { height: 1%; }
#ulcontainer .submenu a:hover {
color: #e88f1d !important;
font-size: 11px;
background-color: #e6e6e6;
padding: #e6e6e6;
height: 18px;
display: block;
}
.submenu_on a:hover{
display:block;
}
.submenu_off a:hover {
display:none;
}
javascript
function DisplaySSmenu(id) {
var tab= new Array(0, 1, 2, 3, 4, 5, 6, 999);
for(var i=0; i<tab.length ; i++) {
if(tab[i]==id) document.getElementById('ssmenu'+tab[i]).style.display="block";
else document.getElementById('ssmenu'+ tab[i]).style.display="none";
}
}
function searchInit() {
var input=document.getElementById('formulaire_recherche').value;
if(input== 'entrer un terme' || input=='enter term') document.getElementById('formulaire_recherche').value='';
}
function popupBlank(url,PopName, width_, height_, scroll_) {
var proprietes;
if (pop) {
pop.window.close();
}
if(!scroll_) scroll_ = 'no';
var top= 0
var left= 0;
if(width_=='' || height_=='') {
width_=screen.width;
height_=screen.height;
proprietes = "toolbar=yes, location=yes, directories=yes, scrollbars=yes, resizable=yes, status=yes, menubar=yes, width="+width_+", height="+height_+", left="+left+",top="+top+"";
} else {
if(width_ > screen.width) {
width_= screen.width;
height_=screen.height;
scroll_ = 'yes';
} else {
proprietes = "toolbar=no, location=no, directories=no, scrollbars="+scroll_+", resizable=yes, status=no, menubar=no, width="+width_+", height="+height_+", left="+left+",top="+top+""
}
}
var pop=window.open(url,PopName,proprietes);
pop.focus();
}
function displayImage(url,PopName, width_, height_) {
//var top= screen.height-(screen.height/1.3);
//var left=screen.width-(screen.width/1.3);
var top=0;
var left=0;
pop = window.open(url, PopName, "toolbar=no, location=no, directories=no, scrollbars=no, resizable=no, status=no, menubar=no, width="+width_+", height="+height_+", left="+left+",top="+top+"");
pop.document.write("<html>");
pop.document.write("<head><title>IFP"+PopName+"</title></head>");
pop.document.write("<body style='margin:0;padding:0' background='"+url+"' onblur='top.close()'>" );
pop.document.write("</body></html>");
pop.document.close();
}
function showPrintButton() {
document.write ("<div id=\"printmap\">");
document.write ("<a href=\"javascript:self.print();\" title=\"Print this page\"><img src=\"ifp2005blue/images/print.png\" alt=\"Print this page\"></a>");
document.write ("</div>");
}
startList = function() {
if (document.all&&document.getElementById) {
navRoot = document.getElementById("nav");
for (i=0; i<navRoot.childNodes.length; i++) {
node = navRoot.childNodes[i];
if (node.nodeName=="LI") {
node.onmouseover=function() {
this.className+=" over";
} // onmouseover end
node.onmouseout=function() {
this.className=this.className.replace(" over", "");
}// onmouserout end
} // end of if
} // end of for
} // end of if document.all
}
window.onload=startList;
//navHover = function() {
// var lis = document .getElementById("navmenu") .getElementsByTagName("LI");
// for (var i=0; i<lis.lenght; i++) {
// lis.onmouseover=function(){
// this.className+="iehover";
// }
// lis[i].onmouseout=function() {
// this.className=this.className.replace(new RegExp("iehover\\b", "");
// }
// }
//}
//if (window.attachEvent) window.attachEvent("onload", navHover);
J'avoue bloquer complètement après avoir tatonné un bon moment, peut-être verrez-vous plus directement le problème...
Pascal[/i][/i][/i][/i][/i]
Modifié par Morfeo (28 Aug 2007 - 07:55)