CSS - Why Don't My Navigation Links Line Up?
Been trying to figure out why my links in my navigation bar (id="extra") won't line up horizontally -- they keep stacking vertically.
Can someone please tell me what I'm doing wrong? Thanks. The important bits are below... Code: <style type="text/css"> html,body{margin:0;padding:0} body{font: 76% arial,sans-serif} p{margin:0 10px 10px} a{display:block;color: #981793;padding:10px} div#header h1{height:80px;line-height:80px;margin:0; padding-left:10px;background: #999966;} div#extra{background:#a4c2c2; text-align:left} div#content p{line-height:1.4} div#navigation{background:#fff} div#footer{background: #999966;color: #333300} div#footer p{margin:0;padding:5px 10px} div#wrapper{float:left;width:100%} div#content{margin-left:200px; background: #fff} div#navigation{float:left;width:200px;margin-left:-100%} div#extra{width:100%} </style> <body> <div id="container"> <div id="header"> <h1 class="logo">Sowanee's</h1> </div> <div id="extra"><div class="navText"> <a href="#">global link</a> | <a href="#">global link</a> | <a href="#">global link</a> | <a href="#">global link</a> | <a href="#">global link</a> | <a href="#">global link</a> | <a href="#">global link</a> </div> </div> </div> <div id="wrapper"> <div id="content"> <p><strong>1) Content here.</strong> </div> </div> <div id="navigation"> <p><strong>2) Navigation here.</strong></p> </div> <div id="footer"><p>Here it goes the footer</p></div> </div> </body> Similar TutorialsHey, i made a header in with some space to get a navigation line over. So i put it in its place with css but when i zoom in or out it won't stay in the middle like evrything else, i tried evrything, display:block, margin:0px, position:absolute http://i.domaindlx.com/wheelofgod/kingjames.asp The navigation bar isn't lining up I use Mozilla Firefox and the 2 images "examples" and "articles" are not in the column no matter how hard I tried. This might be a CSS problem. This is what I have: Code: /* Layout Stylesheet */ body { margin:10px; background:#FFFFFF; color: #333333; text-align:center; padding:0; } #outer { text-align:left; border:1px solid #000000; width:1050px; margin:auto; } #hdr { height:60px; background:#9ACD32; color: #333333; } #bar { height:25px; background:#688E23; color: #FFFFFF; border:solid #000000; border-width:1px 0 1px 0; } #bodyblock { position:relative; background: #FFCC80; color: #FFFF33; width:650px; padding:0; } #l-col { font: Verdana; float:left; background:#9ACD32; color: #333333; width:120px; } #cont { width:800px; background:#FFFFFF; font: verdana; color: #333333; border:solid #000000; border-width:0 0 0 1px; text-align:left; } #ftr { height:25px; background:#9ACD32; color: #FFFFFF; border:solid black; border-width:1px 0 0 0; margin:0; } Code: /* Presentation Stylesheet */ h3, p { margin:0; padding:15px; } h4 { margin:0; padding: 5px 0; } p:first-letter { font-size: 80%; font-weight: bold; color:blue; } /*<![CDATA[*/a.piclink:active{color:red;background-color:grey;text-decoration:none} a.piclink:visited{color:blue;background-color:grey;text-decoration:none} a.piclink:hover{color:#B36B00;background-color:white;text-decoration:none}/*]]>*/ Hi Forum, A small non-profit group I am working with has put together a website. Unfortunately, the horizontal navigation menu disappears on IE browsers. The links are still in place, but are invisible. The shaded boxes around them do not load. Unfortunately we have no idea how to fix it. I am a beginner with CSS-- any helpful hints or advice? Thanks. -Sellicott <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" > <html xmlns="" xml:lang="en" lang="en"> <head> <title>BUTT OUT! Ending Tobacco Industry Exploitation of the Lesbian, Gay, Bisexual and Transgender Community</title> </head> <body> <div id="wrapper"> <div id="header"> <div id="sitename"><img src=></div> </div> <div id="navigation"> %%MENU%% </div> <div id="content-wrapper"> <div id="content">%%CONTENT%%</div> </div> <div id="footer"> <div id="footer-content">%%WEEBLYFOOTER%%</div> </div> </div> </body> </html> *|*{ margin:0pt; padding:0pt; } body{ background:transparent url(pattern3.gif)repeat-x center top; background-color:#FFFFFF; font-family:"lucida grande", arial, sans-serif; font-size:12px; color:#464e54; margin:0; padding:0; } p { line-height:18px; } h1, h2, h3{ line-height:40px; } #wrapper { width:760px; margin:0pt auto; } #header { float:left; width:760px; height:170px; } #sitename { color:#fff; padding-top:0px; font-size:2em; text-transform:uppercase; } #navigation { float:left; height:30px; width:760px; position:relative; } #navigation ul { float:left; padding:5px 10px 0 0; margin-left:0; } #navigation li { float:left; display:inline; font-family:"lucida grande", arial, sans-serif; text-align:center; font-size:1em; font-weight:bold; padding:6px 15px 8px 4px; margin-right:3px; } *html #navigation li { margin-right:4px; padding-right:15px; padding-bottom:9px; } #active { background: transparent url(tab_left2.gif) no-repeat left top; padding:6px 13px 6px 4px; color:#fff; font-weight:bold; } *html #active { padding-right:15px; } #navigation a:link { color:#fff; text-decoration:none; } #navigation a:visited { color:#fff; text-decoration:none; } #navigation a:hover { color:; text-decoration:none; } #active a { background: transparent url(tab_right2.gif) no-repeat right top; color:#464e54; padding:6px 14px 9px 10px; } #active a:link { color:#fff; text-decoration:none; } #active a:hover { color:#fff; text-decoration:none; } #active a:visited { color:#fff; text-decoration:none; } a:link,a:hover,a:visited { color:464e54; font-weight:normal; text-decoration:underline; } a:link { color: #464e54; } a:visited { color: #464e54; } a:active { color: #464e54; } .weebly_header { float:left; background: width:760px; height:1200px; margin-top:35px; } *html .weebly_header { margin-top:28px; padding-top:14px; } #content-wrapper { float:left; background: transparent url(content_background.jpg) no-repeat center top; width:760px; height:700px; } *html #content-wrapper { margin-top:-9px; } #content { padding-top:20px; padding-bottom:20px; } *html #content{ padding-top:35px; } img.image-left { margin-right:15px; float:left; } img.image-right { margin-left:15px; float:right; } #footer { visibility:hidden; padding-top:280px; padding-bottom:10px; float:center; } Hi, I have the following horizontal navigation bar: Code: ul#List { list-style-type:none; margin:0; padding:0; width:956px; font-size:13px; font-weight:bold; } ul#List li { display:inline; } ul#List li a { text-decoration:none; padding:5px 0; width:100px; background:#000000; color:#FFFFFF; float:left; text-align:center; border-left:1px solid #fff; } ul#List li a:hover { background:#ADFF2F; color:#000000; } <ul id="List" style="position:absolute;left:0px;top:90px;"> <li><a style="width:91px;" href="">something something</a></li> ............ </ul> The trouble is when the window is resized (maximized or minimized) at certain points the last list overflows and appears on the next line. How can I prevent this, that is, keep the list on one line when the window is resized. Note I have tried using position:relative and putting the above inside <div> but neither solution worked. If the above code cannot be modified I wonder if someone has a horizontal navigation bar that does what I want. I will be very grateful for all help. Hi, i'm having trouble in my navigation section getting the background color to display behind the links. It works fine in the content section, just not the navigation - why is this? Here is my code - Code: @import url('layout.css'); body { background-image: /images/skyBACK.gif; background-repeat: repeat-y; background-attachment: scroll; background: url('images/skyBACK.gif'); font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 0.8em; } #container { width: 1020px; margin: 10px auto; } #masthead { text-align: center; width: 698px; height: 140px; border-top: 1px solid #dcdcdc; border-right: 1px solid #a9a9a9; border-bottom: 1px solid #808080; border-left: 1px solid #a9a9a9; background-color: #fafaff; } #navigation { position: relative; float: left; width: 148px; margin-top: 10px; margin-bottom: 10px; border-top: 1px solid #dcdcdc; border-right: 1px solid #a9a9a9; border-bottom: 1px solid #808080; border-left: 1px solid #a9a9a9; background-color: #66cccc; } #content { float: left; width: 518px; margin-top: 10px; margin-bottom: 10px; margin-left: 10px; padding: 10px; border-top: 1px solid #dcdcdc; border-right: 1px solid #a9a9a9; border-bottom: 1px solid #808080; border-left: 1px solid #a9a9a9; background-color: #66cccc; } #footer { text-align: center; clear: both; width: 698px; padding-top: 5px; padding-bottom: 5px; border-top: 1px solid #dcdcdc; border-right: 1px solid #a9a9a9; border-bottom: 1px solid #808080; border-left: 1px solid #a9a9a9; background-color: #fefeff; } /* Masthead Styles */ #masthead h1 { color: #3d6c87; } #masthead h3 { color: #5f8ea9; } /* Navigation Styles */ #navigation ul { list-style-type: none; width: 100%; display: block; margin: 0; padding: 0; } #navigation li { display: block; margin: 0; padding: 0; border: 1px solid #fff; background-color: #fff; } #navigation a { color: #0033ff; text-decoration: none; display: block; border: 1px solid #fff; background-color: #fff; } #navigation a:hover { color: #fff; text-decoration: none; border: 1px solid #5f8ea9; background-color: #5f8ea9; } /* Content Styles */ h6 { color: #000000; } h5 { color: #000000; } h4 { color: #000000; } h3 { color: #000000; } h2 { color: #000000; } #content h1 { color: #000000; } #content img { padding: 1px; border: 1px solid #808080; } /* Footer Styles */ #footer p { color: #808080; margin-top: 5px; } #footer a { color: #5f8ea9; text-decoration: underline; } #footer a:hover { color: #33627d; text-decoration: none; } a { color: #0033ff; text-decoration: underline; } a:hover { color: #33627d; text-decoration: underline; } .style_bold { font-weight: bold; } .style_italic { font-style: italic; } This is very strange to me any help would be greatly appreciated. I was just coding this: and all the links appear on new lines... why is that? ARGH! I cant post links just type this: blumoney. latestdot. net/ plb/ pictures. php without the spaces and enters Hey guys im updating a site that i originally didnt code, and for some reason any link will have a carrage return or something after it so that the next thing will start on a new line, so if were to put a link in the middle of a paragragh the next word would start on a new line??? what should i be looking for in the css to rectify this. i tried removing all the 'display : block' but that didnt work... thanks That title is probably a little confusing but it is what's happening. I have an inline list (<li>) that will shift to the right when I hover over links that have been visited. The links that have never been visited do not cause this problem. It's very strange and I'm not sure what's up. The page... http://www.vaska.com/a/ The css... http://www.vaska.com/a/css/c.css To get the menu to appear, hover over the "menu/options" and it will appear. I know for a fact that these issues are not becaused by the javascript in this file...somehow it's a CSS issue. I'm having the problem in Safari and Firefox...I'm not sure about IE/PC and such, but I'm betting the problem is there as well. Thanks for any help...v Hi All, I am building a site that has the following structure for the navigation; Code: <div id="navigation"> <ul id="navlist"> <li class="home"><a href="../index.asp" title="home"><span>home</span></a></li> <li class="aboutus"><a href="../aboutus.htm" title="aboout us"><span>about us</span></a></li> <li class="ourservices"><a href="../ourservices.htm" title="our services"><span>our services</span></a> <ul> <li class="internationalmail"><a href="ourservices_internationalmail.htm" title="international mail"><span>international mail</span></a></li> <li class="worldwidecourier"><a href="ourservices_worldwidecourier.htm" title="worldwide courier"><span>worldwide courier</span></a></li> <li class="worldwidefreight"><a href="ourservices_worldwidefreight.htm" title="worldwide freight"><span>worldwide freight</span></a></li> <li class="storage"><a href="ourservices_storage.htm" title="storage"><span>storage</span></a></li> <li class="publishingservices"><a href="ourservices_publishingservices.htm" title="publishing services"><span>publishing services</span></a></li> </ul> </li> <li class="requestquote"><a href="../requestquote.htm" title="request a quote"><span>request a quote</span></a></li> <li class="contactus"><a href="../contactus.htm" title="contact us"><span>contact us</span></a></li> </ul> </div> The main LI is horizontal, and the containing UL, LI is a vertical dropdown. The seperate CSS file does the image replacements on the <a> and hides the text within the <span>, usual stuff. The nav works great, with the graphic rollovers etc. The rollover, again, standard way of doing it, background: url(<FILE>) no-repeat top left; and the a:hover rollover is a background: bottom left;. Edit: Just noticed that I can't link to the full site that I have uploaded for preview. What I want to do, is when the user roll's over any of the items within the sub-navigation, it keeps the main Services navigation link rolled over also. The only way I could think of doing this, and relatively simply, would be to use JavaScript, but wanted to explore any other CSS ways of doing this. For example, is it possible to change a style of another class, from another? Your help would be much appreciated! I've got two lines of text. Want the spacing the two lines to increase, so I set a line-height. When I do this, not only does it increase space between the two lines, it also increases spacing above the first line (and maybe below the second). How can I increase spacing between the two lines only, without increasing above and below? Thanks! Greetings, I have a class called "header" and I am trying to give it a touch of extra space between it and the next line. All of my headers are just a few words and thus on one line. I tried placing "line-height: 1.5em" in my "header" class and it shows up correctly in Dreamweaver but not in IE. My thought is, because it is only a single line, that class value does not kick in because there is no second line for that class. Is there a way to conrol this in CSS or am I going to have to resort to using a....gulp.....spacer? Thanks in advance! Greetings, I am relatively new to CSS and am using background image bullets. Problem is, in the case of a two line link, the bullet aligns in between the two lines and I need it to align to the top line. Below is the CSS, and attached is a screenshot of the link to better illustrate my predicament. Thanks for any help! li { list-style-type: none; background: url(../images/bullet.gif) no-repeat left; padding: 0 0 0 10px; } Simple question, but i'm trying to create a decent sized space in between my links, and make them white. I can make my links white, but can't seem to change the space inbetween them. HTML Code: div id="bar-links"> <center> <div class="content box1"> <table width="500" border="0" align="center" cellpadding="0" cellspacing="0"> <tr> <td colspan="4"><img src="images/barlist_01.gif" width="500" height="23" alt=""></td> </tr> <tr> <td background="images/barlist_02.gif" width="20"></td> <td background="images/barlist_03.gif" width="456"> </p> <div id="bar-links"> <h4><a href="#" title="Riley's Pub">Riley's Pub</a> <a href="#" title="Ho Down Bar"style="color: #fff">Ho Down Bar</a> <a href="#" title="Depot Square"style="color: #fff">Depot Square Bar</a> <a href="#" title="Egans Pub"style="color: #fff">Egans Pub</a> </h4> </div> </td> <td background="images/barlist_04.gif" width="24"></td> </tr> <tr> <td colspan="4"><img src="images/barlist_05.gif" width="500" height="27" alt=""></td> </tr> </table> </div> CSS Code: #bar-links { text-indent:inherit; text-align:left; } I have a nice little vertical navigation block that I would like to use in multiple pages within the same website. I would like to use the nav block without repeating the code, but I can't figure out how to do it. I have put the code in navigation.htm. What do I do next? Hello. So I'm trying to make my html more semantic, so I'm trying to avoid divs and spans as much as possible. I'm trying to make an unordered list navigation, but it shows up really choppy in IE7. However, the moment I change it from <ul id="navigation"> to <div id="navigation">, it works perfectly. Just for semantics sake I'd like to see if I could keep the ul working. Here's the html code, it validates xhtml strict so you don't have to worry about that. Code: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <link href="css/global.css" rel="stylesheet" type="text/css" /> <title>Eagle Steel Buildings</title> </head> <body> <div id="wrapper"> <img id="banner" src="images/global/banner.jpg" alt="Eagle Steel Building"/> <ul id="navigation"> <li><a href="" class="selected">Home</a></li> <li><a href="">About Us</a></li> <li><a href="">Our Work</a></li> <li><a href="">Free Quote</a></li> <li><a href="">Contact Us</a></li> </ul> <h1>Steel Building Construction</h1> <h2>Lorem Ipsum</h2> <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ut ultrices tortor. In lectus turpis, porta in mollis et, feugiat ac ligula. Vivamus arcu mauris, accumsan id mollis eu, blandit sed odio. Donec id magna nec quam aliquam scelerisque quis in metus. Ut pharetra lorem nec neque condimentum at viverra leo euismod. Fusce vitae orci sed enim bibendum viverra sodales id elit. Fusce lectus purus, rutrum rhoncus consequat non, porta et nisi. Proin vitae est odio. Donec erat orci, mollis id viverra condimentum, feugiat nec est.</p> <h2>Lorem Ipsum</h2> <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ut ultrices tortor. In lectus turpis, porta in mollis et, feugiat ac ligula. Vivamus arcu mauris, accumsan id mollis eu, blandit sed odio. Donec id magna nec quam aliquam scelerisque quis in metus. Ut pharetra lorem nec neque condimentum at viverra leo euismod. Fusce vitae orci sed enim bibendum viverra sodales id elit. Fusce lectus purus, rutrum rhoncus consequat non, porta et nisi. Proin vitae est odio. Donec erat orci, mollis id viverra condimentum, feugiat nec est.</p> <h2>Lorem Ipsum</h2> <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ut ultrices tortor. In lectus turpis, porta in mollis et, feugiat ac ligula. Vivamus arcu mauris, accumsan id mollis eu, blandit sed odio. Donec id magna nec quam aliquam scelerisque quis in metus. Ut pharetra lorem nec neque condimentum at viverra leo euismod. Fusce vitae orci sed enim bibendum viverra sodales id elit. Fusce lectus purus, rutrum rhoncus consequat non, porta et nisi. Proin vitae est odio. Donec erat orci, mollis id viverra condimentum, feugiat nec est.</p> <form id="quoteform" action="quote_home.php" method="post"> <fieldset> <label for="name">Name</label><input type="text" name="name" id="name" /> <label for="date">Date</label><input type="text" name="date" id="date" /> <label for="phone">Phone</label><input type="text" name="phone" id="phone" /> <label for="email">Email</label><input type="text" name="email" id="email" /> <label for="location_zip_code">Location Zip Code</label><input type="text" name="location_zip_code" id="location_zip_code" /> <label for="width">Width</label><input type="text" name="width" id="width" /> <label for="length">Length</label><input type="text" name="length" id="length" /> <label for="sidewall_height">Sidewall Height</label><input type="text" name="sidewall_height" id="sidewall_height" /> </fieldset> </form> </div> </body> </html> And here's the CSS, also validated. Code: /* http://meyerweb.com/eric/tools/css/reset/ */ /* v1.0 | 20080212 */ html, body, div, span, applet, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, big, cite, code, del, dfn, em, font, img, ins, kbd, q, s, samp, small, strike, strong, sub, sup, tt, var, b, u, i, center, textarea dl, dt, dd, ol, ul, li, fieldset, form, label, legend, table, caption, tbody, tfoot, thead, tr, th, td { margin: 0; padding: 0; border: 0; outline: 0; font-size: 100%; vertical-align: baseline; background: transparent; } body { line-height: 1; } blockquote, q { quotes: none; } blockquote:before, blockquote:after, q:before, q:after { content: ''; content: none; } /* remember to define focus styles! */ :focus { outline: 0; } /* remember to highlight inserts somehow! */ ins { text-decoration: none; } del { text-decoration: line-through; } /* tables still need 'cellspacing="0"' in the markup */ table { border-collapse: collapse; border-spacing: 0; } /* Begin Page Styles */ .btest{border:1px solid #FFFFFF;} body { background: #CCCCCC URL('../images/global/steelbg.jpg') top left; margin: 0px; padding: 0px;} #wrapper{ margin: 0px auto; width: 1010px; height: 1000px; background: URL('../images/global/wrappershadow.png') repeat-y;} #banner{ display: block; margin: 0px auto; width: 1000px; height: 250px; } #navigation{ display: block; margin: -2px auto 0px; width: 1000px; height: 38px; list-style-type:none; background: #000000 URL('../images/global/navbg.png') no-repeat;} #navigation a{ float: left; height: 39px; line-height: 2.3em; margin-top:3px; padding-left: 13px; padding-right: 13px; font-size: 1.0em; font-family: Verdana, serif; text-decoration: none; font-weight: bold; color: #CCCCCC; text-align: center;} #navigation a:hover, #navigation a.selected{ text-decoration: underline;} #navigation a.selected{ color: #ff0000;} I have not finished styling the rest of the page, I am only concerned with the navigation right now. I appreciate your time and effort! Hello, I'm new to the forum and not very good with CSS yet. I'm slowly moving from tables to CSS. I set up a sample page to describe the problem I'm having but the forum won't allow me to post the URL here. I have a vertical CSS "LI" navigation section in the left hand sidebar of this web page and it works perfectly in every Mac browser I try it on (very latest Mac versions of Opera, Firefox, Safari, Chrome, Camino, Omniweb, etc.). There's a white, 1-pixel horizontal spacer/separator line between each link in the left sidebar which is supposed to be 220 pixels wide. It is 220 pixels wide on all the Mac browsers I try it on but for some reason, as soon as I try the web page in IE 7 or IE 8, the white horizontal 1-pixel divider line is shorter and ends up being only 195 pixels wide and throws the whole, nice and "even" look off. I don't understand where the 25 pixels are disappearing to in IE 7 and IE 8. Can anyone offer any insight as to what the fix may be or what I've done wrong? Below is the code I've used to create the navigation. Thanks so much. HTML Code: Code: <div id="navcontainer"> <ul id="navlist"> <li id="active"><a href="#" id="current">Home</A></li> <li><a href="#">On To Page 2</A></li> <li><a href="#">On To Page 3</A></li> <li><a href="#">On To Page 4</A></li> <li><a href="#">On To Page 5</A></li> </ul> </div> CSS Code: Code: #navlist { padding-left: 25px; margin-left: 0; width: 220px; } #navlist li { list-style: none; margin: 0; padding: 0.25em; border-top: 1px solid white; } #navlist li a { background: transparent url(../images/list_off.gif) left center no-repeat; padding-left: 15px; text-align: left; font-family: Arial, Helvetica, Verdana, sans-serif; font-size: 12px; font-weight: bold; color: #277eb1; text-decoration: none; line-height: 30px; } #navcontainer ul li a:hover { background: transparent url(../images/list_on.gif) left center no-repeat; color: #da251c; } #navcontainer ul li a#current { background: transparent url(../images/list_active.gif) left center no-repeat; color: #999999; } hi, i was wondering if anyone knw any links to ultra super dooper cool websites for css navigations. I want to learn how to do ace ones. I have already googleed about, I found the sliding doors on ALA an stuff but i need that little bit more cool tutorials prefrably!! I did find one cool one athttp://www.bulkherbstore.com/ thanks tom. I'm pretty new to CSS, but I've managed to put together a website based from a psd, that validates and everything has gone well. My menu, however, is pretty shoddy. I have everything positioned the way I want it, but what I want to do is convert the lists inside from dropping down to being horizontal parallell to the nav bar itself. From: --- --- --- --- | | To: _ _ _ --- --- --- --- The site is here. Ignore the issues with the absolute positioning; its because of the ads at the top, and it doesn't affect the nav bar. I am desperatefor some help, it is ridiculous to figure out. Anyone who can help me, I would be crazy grateful. Thanks, Tom Code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <style type="text/css"> /*BEGINNING OF CSS*/ body{ padding: 0px; background-color: #000000; font-family: Verdana; color: #FFFFFF; text-align: center; } div.container { margin: 0 auto; padding: 0px; width: 1024px; text-align: left; } div.left { float: left; } div.right { float: right; } div.logo { margin: 0 auto; background-position: top center; text-align: center; } div.header { text-align: center; padding-top: 0px; } div.navigation { background-color: #000000; background-image: url(http://i39.tinypic.com/igm16v.jpg); overflow: auto; } div.content { background-color: #000000; background-image: url(http://i39.tinypic.com/2ce2qus.jpg); overflow: auto; height: 525px; margin: 0 auto; } div.footer { background-color: transparent; background-image: url(http://i39.tinypic.com/2vjsbrp.jpg); overflow: auto; height: 290px; padding: 0px; margin: 0 auto; } p.head { text-align: left; font-size: 24px; } p.content { position: relative; font-size: 12px; } a.main { text-decoration: none; font-size: 18px; padding: 8px; color: #FFFFFF; background-color: transparent; } a.sub { font-size: 16px; line-height: 150%; text-align: left; text-decoration: none; color: #999999; background-color: transparent; } a.plain { text-decoration: none; font-size: 12px; color: #FFFFFF; background-color: transparent; } a.plainfoot { text-decoration: none; font-size: 12px; color: #959595; opacity: 90%; background-color: transparent; border-bottom: 1px solid #0d0f10; opacity: 100%; } #nav, #nav ul { margin: 0 auto; padding: 0px; list-style: none; } #nav a.main { display: block; margin-left: 5px; } #nav a.sub { display: block; width: 150px; margin-left: 5px; } #nav li { float: left; width: 5em; } #nav li ul { position: absolute; width: 1em; left: -999em; } #nav li:hover ul { left: auto; } #nav li ul { position: absolute; padding: 7px; width: 1em; left: -999em; } #nav li:hover ul { left: auto; } #nav li:hover ul, #nav li.sfhover ul { left: auto; font-family: lucida grand; } h1.footer { position: relative; font-size: 18px; color: #123712; margin-bottom: 0%; margin-left: 50px; } p.footer { font-size: 12px; color: #909090; margin-left: 50px; max-width: 200px; text-decoration: none; } h1.main { font-size: 28px; font-weight: 200; margin-left: 140px; padding: 0; text-shadow: #959595; } p.content { font-size: 12px; color: #FFFFFF; line-height: 130%; margin-left: 140px; max-width: 450px; text-decoration: none; } div.date { background-color: transparent; background-image: url(http://i39.tinypic.com/xnc3de.jpg); background-repeat: no-repeat; padding: 0px; margin-top: 17px; margin-left: 0px; } h1.main2 { font-size: 28px; font-weight: 200; margin-left: 140px; text-shadow: #959595; } p.content2 { font-size: 12px; line-height: 130%; margin-left: 140px; max-width: 450px; text-decoration: none; } div.date2 { background-color: transparent; background-image: url(http://i39.tinypic.com/xnc3de.jpg); background-repeat: no-repeat; padding: 0px; min-height: 100px; margin: 0px; } div.sidebar { background-color: transparent; background-image: url(http://i41.tinypic.com/2r76kpu.jpg); background-repeat: no-repeat; background-position: top right; padding: 0px; min-height: 200px; margin-top: 15px; margin-right: 15px; } div.datetext1 { position: absolute; background: transparent; font-family: verdana, sans-serif; font-size: 12px; font-weight: 200; color: #FFFFFF; left: auto; top: 382px; padding-top: 262px; padding-left: 44px; } div.dateid1 { position: absolute; background: transparent; font-family: verdana, sans-serif; font-size: 24px; font-weight: 300; color: #123712; left: auto; top: 382px; padding-top: 281px; padding-left: 47px; } div.datetext2 { position: absolute; background: transparent; font-family: verdana, sans-serif; font-size: 12px; font-weight: 200; color: #FFFFFF; left: auto; top: 382px; padding-top: 44px; padding-left: 44px; } div.dateid2 { position: absolute; background: transparent; font-family: verdana, sans-serif; font-size: 24px; font-weight: 300; color: #123712; left: auto; top: 382px; padding-top: 63px; padding-left: 47px; } div.sidebarhead { position: absolute; background: transparent; font-family: verdana, sans-serif; font-size: 18px; font-weight: 200; color: #123712; text-align: center; left: auto; top: 400px; padding-top: 15px; padding-left: 630px; } div.sidebartext { position: absolute; background: transparent; font-family: verdana, sans-serif; font-size: 10px; color: #FFFFFF; line-height: 130%; text-align: left; max-width: 168px; left: auto; top: 400px; padding-top: 50px; padding-left: 610px; } /*END OF CSS*/ </style> <script type="text/javascript"> sfHover = function() { var sfEls = document.getElementById("nav").getElementsByTagName("LI"); for (var i=0; i<sfEls.length; i++) { sfEls[i].onmouseover=function() { this.className+=" sfhover"; } sfEls[i].onmouseout=function() { this.className=this.className.replace(new RegExp(" sfhover\\b"), ""); } } } if (window.attachEvent) window.attachEvent("onload", sfHover); </script> <title>Obsidian Recording Front Page</title> </head> <body> <div class="container"> <div class="left"> <img src="http://i39.tinypic.com/14j6nsz.jpg" alt="left column"/> </div> <div class="right"> <img src="http://i40.tinypic.com/b4yir5.jpg" alt="right column"/> </div> <div class="logo"> <img src="http://i40.tinypic.com/2u77lua.jpg" alt="logo"/> </div> <div class="header"> <img src="http://i41.tinypic.com/1178qo6.jpg" alt="header"/> </div> <div class="navigation"> <ul id="nav"> <li><a class="main" href="http://www.obsidianrecording.com">Home</a></li> <li><a class="main" href="#">Music</a> <ul> <li><a class="sub" href="http://www.obsidianrecording.com/featured">Featured</a></li> <li><a class="sub" href="http://www.obsidianrecording.com/artists">Artists</a></li> <li><a class="sub" href="http://www.obsidianrecording.com/artists/thisisthefall">My Band</a></li> </ul> </li> <li><a class="main" href="http://www.obsidianrecording.com/design">Design</a></li> <li><a class="main" href="#">Store</a> <ul> <li><a class="sub" href="http://www.obsidianrecording.com/store/recording">Recording</a></li> <li><a class="sub" href="http://www.obsidianrecording.com/store/design">Design</a></li> <li><a class="sub" href="http://www.obsidianrecording.com/store/music">Music</a></li> </ul> </li> <li><a class="main" href="#">About</a> <ul> <li><a class="sub" href="http://www.obsidianrecording.com/about/rates">The Rates</a></li> <li><a class="sub" href="http://www.obsidianrecording.com/about/studio">The Studio</a></li> <li><a class="sub" href="http://www.obsidianrecording.com/about/tomhoneyman">Tom Honeyman</a></li> </ul> </li> </ul> </div> <div class="content" <div class="date"> <div class="sidebar" <h1 class="main">Cast into Shadows</h1> <p class="content">The first band ever to record at Obsidian Recording was Cast into Shadows. I'd like to shout out to Donnie, Evan, Josh, Brian, and J.T. for being the first group to come through here and for making a kickass record along the way. You can find more about them in the Artists section of the site.</p> </div> </div> <div class="date2"> <h1 class="main2">Website Launched!</h1> <p class="content2">After a looong time working on this site, I've finally finished just in time for summer! What you can expect is a lot of updates on what artists who record here are doing, free downloads, cool videos of their shows, special rates just for people who visit the site, and more. If you'd like to contact me, all my information and more is in the About section of the site. <br /><br /> Thanks for visiting, and I hope you enjoy!</p> </div> <div class="datetext1">Jun</div> <div class="dateid1">1</div> <div class="datetext2">Jun</div> <div class="dateid2">7</div> <div class="sidebarhead">New Website!</div> <div class="sidebartext">Welcome to the all-new Obsidian Recording site! I will regularly update with news, special rates, videos, featured free downloads, and more.</div> </div> <div class="footer"> <br /><br /><br /> <h1 class="footer">Recent Projects</h1> <p class="footer"><a class="plainfoot" href="www.obsidianrecording.com/artists/castintoshadows">Cast into Shadows</a><br /><br /><a class="plainfoot" href="http://www.obsidianrecording.com/artists/thisisthefall">This is the Fall</a></p> </div> </div> </body> </html> Hey guys I am currently having an issue with a CSS Navigation. I was wondering if anyone was available to help me out. http://schoolwide.sgajewski.com/menu/ I am currently having an issue with IE 7. It seems to be working in every other browser but the second level of the navigation is offset lower in IE7. The spacing starts off 1 pixel two low and progressively the gap gets wider. Code: ul.vertical, ul.vertical li { margin:0; padding:0; list-style-type:none; font-size:100%; } ul.vertical { position:absolute; z-index:1000; cursor:default; width:180px; left:1em; top:4.05em; } ul.vertical li { position:relative; text-align:left; cursor:pointer; cursor:hand; width:180px; margin:-1px 0 0 0; padding-bottom:0px!important; padding-bottom:1px; float:left; clear:both; top:0; left:0; } ul.vertical ul { z-index:1020; cursor:default; position:absolute; width:197px; margin:0 0 0 179px; top:-100em; left:-1px; padding:1px 0 0 0; height:0px; overflow:hidden; } ul.vertical ul li { width:197px; } ul.vertical ul ul { margin: 0 0 0 179px; } @media Screen, Projection { ul.vertical li:hover > ul { top:0; height:auto; overflow:visible; } } ul.vertical a, ul.vertical a:visited { display:block; cursor:pointer; cursor:hand; background:url(images/bg.jpg); padding:5px 7px; font:normal normal bold 0.7em tahoma, verdana, sans-serif; color:#008000; text-decoration:none; letter-spacing:1px; } ul.vertical a:hover, ul.vertical a:focus, ul.vertical a.rollover, ul.vertical a.rollover:visited { background:url(images/bg_over.jpg); color:#806020; } ul.vertical .outtop {background:url(images/bg_over_top.jpg);} ul.vertical .outbg {background:url(images/bg_over_mid.jpg);} ul.vertical .outbot {background:url(images/bg_over_bot.jpg);} ul.vertical ul a, ul.vertical ul a:hover, ul.vertical ul a:visited, ul.vertical ul a:active ul.vertical ul a:hover, ul.vertical ul a:focus, ul.vertical ul a.rollover, ul.vertical ul a.rollover:visited { background-image:none; } @media screen, projection { * html ul.vertical li { display:inline; f\loat:left; background:#ffffff; } } * html ul.vertical li { position:static; } * html ul.vertical a { position:relative; } ul[class^="vertical"] ul { display:none; } ul[class^="vertical"] ul { displa\y:block; } Any help on why this is offset in IE7 would be great. Thanks in advance. |