• Jetzt anmelden. Es dauert nur 2 Minuten und ist kostenlos!

CSS DropDown Menu IE 7/8 Problem

pixel90

Neues Mitglied
Hallo Leute,

ich zweifel hier gerade so richtig an meinen html und css Kenntnissen, da ein DropDown Menü (reines CSS) nur im IE nicht funktioniert. Es werden die Submenüs nicht aufgeklappt. Hier ist der Quellcode:

HTML:
HTML:
<ul class="menu">
	<li id="item-435" class="current active">
		<a href="#" >Home</a>
	</li>
	<li id="item-294" class="parent">
		<a href="#" >Site Map</a>
		<ul>
			<li id="item-290"><a href="#" >Articles</a></li>
			<li id="item-438" class="parent"><a href="#" >Weblinks</a>
			<ul>
				<li id="item-465"><a href="#" >Sub Sub Menu Item</a></li>
				<li id="item-466"><a href="#" >Sub Sub Menu Item (2)</a></li>
			</ul>
			</li>
			<li id="item-439"><a href="#" >Contacts</a></li>
		</ul>
	</li>
	<li id="item-238" class="parent"><a href="#" >Sample Sites</a>
		<ul>
			<li id="item-445"><a href="#" >Parks</a></li>
			<li id="item-446"><a href="#" >Shop</a></li>
		</ul>
	</li>
	<li id="item-455"><a href="#" >Example Pages</a></li>
</ul>




CSS:
HTML:
#topnav ul.menu,
#topnav ul.menu li,
#topnav ul.menu ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

#topnav ul.menu {
	position: relative;
	z-index: 597;
	float: left;
}

#topnav ul.menu li {
	float: left;
	line-height: 1.3em;
	vertical-align: middle;
}

#topnav ul.menu li.parent {
	background: url(../images/topnav_arr.png) no-repeat right center;
}

#topnav ul.menu li ul li.parent  {
	background: url(../images/topnav_sub_arr.png) no-repeat right center;
}

#topnav ul.menu li ul ul li.parent  {
	background: url(../images/topnav_sub_arr.png) no-repeat right center;
}

#topnav ul.menu li.hover,
#topnav ul.menu li:hover {
	position: relative;
	z-index: 599;
	cursor: default;
}

#topnav ul.menu ul {
	display: none;
	position: absolute;
	top: 100%;
	left: 0;
	z-index: 598;
	width: 100%;
}

#topnav ul.menu ul li {
	float: none;
}

#topnav ul.menu ul ul {
	top: 0;
	left: 100%;
}

#topnav ul.menu li:hover > ul {
	display: block;
}

/* Menu Style */
#topnav {

}

#topnav ul.menu {
	float: right;
}

#topnav ul.menu li {
}

#topnav ul.menu li.hover,
#topnav ul.menu li:hover {
}

#topnav ul.menu li {
	opacity: 0.7;
	filter: alpha(opacity = 70);
	padding: 0 20px;
	height: 70px;
	display: block;
}

#topnav ul.menu li a{
	font-family: 'Yanone Kaffeesatz', arial, serif;
	font-size: 18px;
	line-height: 70px;
	text-shadow: none;
}

#topnav ul.menu a:link,
#topnav ul.menu a:visited { 
	color: #fff; 
	text-decoration: none; 
}

#topnav ul.menu li:hover { 
	opacity: 0.6;
	filter: alpha(opacity = 60);
	background: #000;
}

#topnav ul.menu ul {
	width: 200px;
	margin-top: 0;
	background: #000;
}

#topnav ul.menu ul li a {
	line-height: 30px;
	font-size: 16px;
}

#topnav ul.menu ul li {
	height: 30px;
}

#topnav ul.menu ul li:hover, #topnav ul.menu ul li.parent:hover {
	opacity: 1;
	filter: alpha(opacity = 100);
	background: #222;
}


Vielen Dank für die Hilfe im Vorraus ;)
 
ja,


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-gb" lang="en-gb" >
 
Warum denn so kompliziert?


HTML-Code:


<tr>

<td>



<div id="content">

<div id="menu">

<a href="index.php">Home</a>

<a href="index.php?page=5">Gewünschter Punkt</a>

<a href="index.php?page=38">Gewünschter Punkt</a>

<a href="index.php?page=183">Gewünschter Punkt</a>

<a href="index.php?page=37">Gewünschter Punkt</a>

<a href="index.php?page=29">Gewünschter Punkt</a>

<a href="index.php?page=57">Gewünschter Punkt</a>

<a href="index.php?page=187">Gewünschter Punkt</a>

<a href="index.php?page=173">Gewünschter Punkt</a>

</div></div>

</td>

</tr>



Da sist ja die Navigation c;
 
@-=GlobalLove=-:
1. Du verwendest Tabellen
2. Navigationsleisten werden i.d.Regel als Listen geschrieben
3. Dein Menu ist nicht aufklappbar; dh. zuviele unübersichtliche Informationen

@pixel90:
Der IE unterstützt nur a:hover, also div:hover; li:hover etc. funzt im IE nicht
 
@pixel90: Hast Du einen Link zur Seite parat?

@-=GlobalLove=-: Menüs zeichnet man nicht als Tabellen aus. Daher ist ein Tipp falsch, irreführend und hat eigentlich auch nichts mit der Fragestellung zu tun.

@alogheo: Auf IE6 trifft das zu. IE7 und IE8 um die es hier geht unterstützen es jedoch.
 
So in etwa: www.habbotimes.de? ?





HTML-Code:




<div id="headerhome">
<div id="topnavigation">
<div id="topnavigationbuttons">
<div style="float:right;height:28px" onmouseover="scaleTopnews(0,'subnav_community');" onmouseout="scaleTopnews(1,'subnav_community');">
<a style="float:none" class="topnav_community" href="/community">Forum</a>
</div>
<div style="float:right;height:28px" onmouseover="scaleTopnews(0,'subnav_galerie');" onmouseout="scaleTopnews(1,'subnav_galerie');">
<a style="float:none" class="topnav_galerie" href="/galerie">Galerie</a>
<ul id="subnav_galerie" class="subnav">
<li><a style="float:none;" href="http://www.habbotimes.net/galerie/maennlich">Jungen/Männer</a></li>
<li><a style="float:none;" href="http://www.habbotimes.net/galerie/weiblich">Mädchen/Frauen</a></li>
<li><a style="float:none;" href="http://www.habbotimes.net/galerie/howto">Anleitung</a></li>
</ul>
</div>
<div style="float:right;height:28px" onmouseover="scaleTopnews(0,'subnav_fancenter');" onmouseout="scaleTopnews(1,'subnav_fancenter');">
<a style="float:none" class="topnav_fancenter" href="/fancenter">Fancenter</a>
<ul id="subnav_fancenter" class="subnav">
<li><a style="float:none;" href="http://www.habbotimes.net/fancenter/galerie">Foto Galerie</a></li>
<li><a style="float:none;" href="http://www.habbotimes.net/fancenter/habboimager">Habbo Imager</a></li>
<li><a style="float:none;" href="http://www.habbotimes.net/fancenter/schriftgenerator">Font-o-matic</a></li>
<li><a style="float:none;" href="http://www.habbotimes.net/fancenter/pixxelsearch">Pixxel Search</a></li>
<li><a style="float:none;" href="http://www.habbotimes.net/fancenter/userbar">Userbar</a></li>
<li><a style="float:none;" href="http://www.habbotimes.net/fancenter/raumideen">Raumideen</a></li>
<li><a style="float:none;" href="http://www.habbotimes.net/fancenter/wallpaper">Wallpaper</a></li>
<li><a style="float:none;" href="http://www.habbotimes.net/fancenter/topstory_gallery">Topstory Bilder</a></li>
</ul>
</div>







Das ist der Code wie die das da gemacht haben c;
 
Einen link habe ich leider nicht, da ich lokal entwickle, aber ich werde mal das mit dem a:hover ansehen, vielleicht krieg ich es doch noch hin ...
Werde dann die Lösung posten ;)
 
Zurück
Oben