hoffparkett
New Member
I am having an issue with this horizontal menu bar. It is suppose to fit the window (width wise) but continues a little bit further than it should. It is also suppose to be top:0;left:0;Everything I do either one of two things works. Either I align it the top left but the width is too large, or it's not aligned and the width does fit.\[code\] <!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"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Website Title</title> </head> <body> <style> body{ } .bg{ width: 100%; height: 100%; position: absolute; top: 0; left: 0; z-index: -5000; } #cssmenu ul { list-style-type:none; width:100%; position:absolute; display:block; height:33px; font-size:.6em; background: #76B3F1 url(images/menu-bg.png) repeat-x top left; font-family:Verdana,Helvetica,Arial,sans-serif; border:1px solid #000; margin:0; padding:0; top:0; left:0; } #cssmenu li { display:block; float:left; margin:0; padding:0; } #cssmenu li a { float:left; color:#A79787; text-decoration:none; height:24px; padding:9px 15px 0; font-weight:normal; } #cssmenu li a:hover,.current { color:#fff; background: #A3BAE6 url(images/menu-bg.png) repeat-x top left; text-decoration:none; } #cssmenu .current a { color:#fff; font-weight:700; } </style> <div id="cssmenu"> <ul> <li class='active '><a href='http://stackoverflow.com/questions/15582829/#'><span>Home</span></a></li> <li><a href='http://stackoverflow.com/questions/15582829/#'><span>Products</span></a></li> <li><a href='http://stackoverflow.com/questions/15582829/#'><span>Company</span></a></li> <li><a href='http://stackoverflow.com/questions/15582829/#'><span>Contact</span></a></li> </ul> </div> <div id="background"> <img src="http://stackoverflow.com/questions/15582829/background/001.JPG" class="bg"/> </div> </body> </html>\[/code\]