CSS - Extra Vertical Space Between Lines In Ie
I'm going through hell trying to make a site look the same in IE and Firefox. The biggest problem is the gaping spaces IE adds between elements. What is the best way to fix this?
Example at patrolmag.com/new. Any advice or help would be most appreciated. P.S. How the page looks in Firefox 3 is ideal. I just need to make at least IE7 come somewhere close to matching it. Similar TutorialsI have a few lines of text which have different formatting setups. But there seems to be an extra space between the two lines of text. Why is this? Here is the css for the text: Code: h1{ color:#534741; text-decoration : none; font : 20px 'lucida sans', 'lucida sans unicode', 'lucida grande', 'trebuchet ms', helvetica, arial, sans-serif; text-align:left; font-weight: bold; padding-left: 18px; } h2{ font-size: 16px; color:#1133aa; text-align:left; padding-left: 0px; padding-right: 20px; } h3{ font-size: 12px; color:#534741; text-align:left; padding-left: 0px; padding-right: 20px; } Here is the text itself: Code: <div id="centerformbottom"> <h1>or call</h1> <div id="centerformbottomleft"> <h2>Janine Todd</h2> <h3>312.848.9388 <a href="mailto:janine@imaginehealthsolutions.com ">janine@imaginehealthsolutions.com </a></h3> </div><!--centerformbottomleft--> <div id="centerformbottomright"> <h2>Bob Brodell</h2> <h3>312.659.4242 <a href="mailto:bob@imaginehealthsolutions.com">bob@imaginehealthsolutions.com</a></h3> </div><!--centerformbottomright--> </div><!--centerformbottom--> Here's a link to the page itself: http://www.childevangelismncwi.org/ImageHealth/Contact.htm Thanks! I have a few lines of text inside a nested div. Everything is fine if I leave it at that but as soon as I add some more, the whole page (wrapper) get shifted left by 9 pixels. It causes a 'jump' hen navigating between this page and the rest of the site. All of these pages are quite simple and were created from the same index page. HTML Code: <div id="wrap"> <div id="content_awards"> <div id="subcontent_awards"> <div class="award_col"> <h3>Subtitle 1</h3> Winner<br /><br /> <h3>Subtitle 2</h3> Winner<br /><br /> <h3>Subtitle 3</h3> Commended<br /><br /> <!-- <h3>Subtitle 4</h3> Commended<br /><br /> --> </div> <br style="clear:both;" /> </div> <br style="clear:both;" /> </div> <br style="clear:both;" /> </div> CSS Code: body { padding:2px 0 0 0; margin:0; text-align:center; font-size:14px; background-color:#FFFFFF; } #wrap { margin:0 auto; width:760px; padding:0; text-align:center; } #content_awards { margin:0 auto; padding:20px 0 0 0; width:754px; color:#FFFFFF; text-align:left; background-color:#31578E; clear:both; } #subcontent_awards { margin:0 auto; padding:0 10px 10px 10px; width:734px; background-image:url('images/bg_awards_shadows.jpg'); background-repeat:no-repeat; background-color:#31578E; clear:both; } div.award_col { float:left; margin:0 0 0 1px; padding:0 10px 0 20px; width:152px; line-height:130%; font-size:12px; } Thanks, Anyone knows of a method to cause a vertical line to come all the way down ? Currently it stops where the text stops. but i want it to go all the way to the buttom of the document regardless of the text. (right now i use box border on one side) Thanks! I'm working on a web site that has a jFlow slideshow (not implemented just yet) and I was mocking up a page with just a plain img in its place. When the page is viewed in FF 3.5, there is extra space to the right and bottom of the image. However, it shows as expected in IE8. I can't figure this out for the life of me. If I "use border box model" from the Google Web Developer toolbar in FF, it shows as desired as well. Here's a link to the file: http://www.websimage.com/3238/index2.html I've been trying to figure this out for a while now and I'm getting nowhere but frustrated, so any help you could provide would be *greatly* appreciated. EDIT: I've found some information regarding box-models, and have applied the -moz-box-model: border-box; which seems to have eliminated the additional space within the gray div...however, there is an additional 10px of unwanted padding on the right & left of it now. I can live with this, but I don't want to if I don't have to. Edit #2: If I take out the margin-left: auto; and margin-right: auto; (to center it) the extraneous padding is not on the left, but is added to the extraneous padding on the right. All the math adds up when it comes to the widths and padding specified for the respective "wrappers" so I'm at a loss as to what's causing this. So I am trying to move from designing in <tables> and move on to the beauty of the CSS box-model design. I have been inspired by one of the ZenGarden designs and wanted to see if I could try and duplicate it's flow. I am running into a problem. I have created the outer box "#mainBox" and nested within this I have a child "#pageHeader." Problem is that there is this big amount of space (that is present in both IE6 AND FireFox 1.0) at the bottom of "#pageHeader." See the attached pic for the exact detail. Here is my code: Code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/loose.dtd"> <html><head><title>The Shalom Foundation</title> <style type="text/css"> <!-- body { text-align:center; background-color:#666666; margin:0 0 50px 0; /* top right bottom left */ } p{ padding:0; margin:0; text-align:justify; } #mainBox { float:right; margin:9px 12px 0 0; padding:0px; width:733px; text-align:left; background-color:#999999; } #pageHeader{ background: url(images/layout/header.jpg) no-repeat top left; padding:0; margin:0; text-indent: -15000px; height: 290px; overflow: hidden; } #nav{ position:absolute; right:100px; margin:0; background: url(images/layout/menu.jpg) no-repeat top left; padding:0; margin:0; width:136px; height: 302px; overflow: hidden; } --> </style> </head> <body> <div id="mainBox"> <div id="pageHeader">The Shalom Foundation</div> <div id="nav">Nav</div> <div id="contentHdr"><table width="100%" height="100%" cellpadding="0" cellspacing="0" border="0"><tr><td valign="middle"><img src="images/layout/hdr_about_us.gif"></td></tr></table></div> <div id="content"><p>Magnus es, domine, et laudabilis valde: magna virtus tua, et sapientiae tuae non est numerus. et laudare te vult homo, aliqua portio creaturae tuae, et homo circumferens mortalitem suam, circumferens testimonium peccati sui et testimonium, quia superbis resistis: et tamen laudare te vult homo, aliqua portio creaturae tuae.tu excitas, ut laudare te delectet, quia fecisti nos ad te et inquietum est cor nostrum, donec requiescat in te. da mihi, domine, scire et intellegere, utrum sit prius invocare te an laudare te, et scire te prius sit an invocare te. sed quis te invocat nesciens te? aliud enim pro alio potest invocare nesciens. an potius invocaris, ut sciaris? quomodo autem invocabunt, in quem non crediderunt? aut quomodo credent sine praedicante? et laudabunt dominum qui requirunt eum. quaerentes enim inveniunt eum et invenientes laudabunt eum. quaeram te, domine, invocans te, et invocem te credens in te: praedicatus enim es nobis. invocat te, domine, fides mea, quam dedisti mihi, quam inspirasti mihi per humanitatem filii tui, per ministerium praedicatoris tui.</p></div> <div id="rightNav">rightNav</div> <div id="pageFooter">pageFooter</div> </div> </body> </html> Thanks in advanced for any help! http://www.zombiepolitics.com Just when I thought I had this down .. I dont. I have a CSS layout .. there are two main divs side by side, the navigation rests at the top of the right div. problem is in IE 6 there is so much extra space at the top that my navigation doesnt line up with my header .. in FF its no problem. What is the workaround for this? It seems that whenever I create a dashed/dotted, verticle line in CSS and view it in IE6, and scroll, the line gets all blurred and messed up. Does anyone know about this and if there is a way to fix this? Hi: After entering data into a database from a form (HTML) using php, I now have to retrieve the data, place it in a form style and print. Everything works fine when I do the print except for one thing. Description of Problem: When I print using IE 6.0, all vertical and horizontal lines which separate data from each other (cells) print. When I do the print in Mozilla, only the horizontal lines appear. How can I fix this, or, what makes it do this in Mozilla and not in IE? There is one thing I'm not doing, I'm not using CSS to format the form. Could this fix the problem? Any suggestions will be greatly appreciated! Thanks! I have 2 columns. The main one and the sidebar. The problem is that the sidebar extends down the page further then the main column. I am using a color in the background. The color does not extend all the way down. The main area stops about half way down the sidebar and just leaves white space there. The whole page is colored except for this square of white in the middle. Also if I extend the main area content to be longer then the sidebar then the sidebar will have white underneath it instead. Hi, Can anyone please explain why the more text I add to the main content area 'full-size' div.... the more spacing gets added below it. Is there a way to stop this? example herel Code: /*begin normal CSS ----------------------------------------------------*/ body { text-align: center; background: #362f25; color: #333; font: 12px "Trebuchet MS", Arial, Helvetica, sans-serif; } #wrap { margin: 0 auto; width: 960px; text-align: left; background: #f8f4f2 url(images/bg-wrap.gif) repeat-y 0px 0px; padding-bottom: 5px; } /*classes ----------------------------------------------------*/ .full-size { margin-left:20px; margin-top:20px; width: 700px; font: 12px; position:relative; left:180px; top:-370px; } /*header ----------------------------------------------------*/ #header { height: 50px; background: #362f25; color: #d2cccb; font: 15px "Palatino Linotype", Arial, Helvetica, sans-serif; } /* left nav menu ----------------------------------------------------*/ #navcontainer { width: 170px; border-right: 1px solid #000; padding: 0 0 0 0; margin-bottom: 10px; font-family: Verdana, Lucida, Geneva, Helvetica, Arial, sans-serif; background-color: #90bade; color: #333; position:relative; left:0px; top:-30px; } #navcontainer ul { list-style: none; margin: 0; padding: 0; border: none; } #navcontainer li { border-bottom: 1px solid #90bade; margin: 0; } #navcontainer li a { display: block; padding: 5px 5px 5px 0.5em; border-left: 15px solid #006865; border-right: 10px solid #203654; background-color: #2175bc; color: #fff; text-decoration: none; width: 100%; } html>body #navcontainer li a { width: auto; } #navcontainer li a:hover { border-left: 15px solid #203654; border-right: 10px solid #006865; background-color: #2586d7; color: #fff; } I have an extra PHPNuke (Ravennuke 2.02) module for the start page. Several pieces of information are displayed in various cells of a table. I have a problem were there is some extra space at the beginning of a table that I cannot get rid of. I saved the output and uploaded he http://www.linux-tutorial.info/index_test3.html after the site title and before the tag line "The place where you learn Linux", there is a large space. In this example, the title is in a separate table, followed by a new table for the information blocks. If I put them in the same table the space appears before the title block. The relevant block of code looks like this: Code: <table border="0" cellpadding="0" cellspacing="0" width="100%"> <tr valign="top"> <td class="welcome_title_box" valign="top" colspan="2"> <div align="center" class="welcome_main_title"> Welcome to the <br>Linux Knowledge Base and Tutorial</div> </td></tr></table> <table border="0" cellpadding="0" cellspacing="0" width="100%"> <tr><td valign="top" width="50%"> <span class="subtitle">"The place where you learn Linux"</span> <br><br> Looking for an in-depth and easy-to-understand introduction to Linux? Then look no further! <br> We don\'t just show you how to execute a handful of commands and use a few utilities. The Linux Tutorial goes beyond the basics, providing you with the knowledge necessary to get the most out of your Linux system. <br><br> Jump right in by clicking <a href="http://www.linux-tutorial.info/modules.php?name=MContent&pageid=224"> here</A>. </td> If I removed the highlighted code, the space appears before the site title. If I remove the whole DIV containing the title, I still have the space above the tag line. This says to me that it is not related to the division. It seems that this row or the table itself is pulling the formatting from somewhere else. That would be a logical consequence of the cascading aspect of CSS, but I do no see where it is gettign the space from. Admittedly I am not all that good with CSS/formatting, so it is possible (if not likely) that I overlooked something. Note that in the index_test3.html, I close the table at the end of the first row (prior to the list of news and threads) then open a new table: Code: </table><table border="0" cellpadding="0" cellspacing="0" width="100%" > If I change BGCOLOR for the first table and then change the line above to this: Code: </table>HERE<table border="0" cellpadding="0" cellspacing="0" width="100%" bgcolor="RED"> The space is after the word "HERE". If I remove this code, the extra space is right after the row/div with the site title and before the row with the tag-line. This all make me think that the extra space is being added before the next table, as opposed to at the end of the previous table. There are a number of posts in the CSS forum that I tried like changing the margin (style="margin: 0px"), but none of the solutions solved the problem. I have tried all sorts of combinations of spacing and alignment, but I cannot get rid of this space. I have tried loaded the page with multiple browsers (Konqueror, FIrefox, IE 6) with the same results, so I do not think it is a browser specific issue. Any and all input is greatly appreciated. For some reason, I cannot for the life of me figure out why Firefox is adding space at the top of my page. I have a container div that contains my header, body, and footer. I have done this: Code: #container{ width: 732px; margin: 0px auto; } Too me that should fix the issue. I even tried applying that code to the body{ ... } but that doesn't work either. Has anyone else gone through this before. There is no space in IE6 or IE7. Thanks, teamhonda81 For some reason, I cannot for the life of me figure out why Firefox is adding space at the top of my page. I have a container div that contains my header, body, and footer. I have done this: Code: #container{ width: 732px; margin: 0px auto; } Too me that should fix the issue. I even tried applying that code to the body{ ... } but that doesn't work either. Has anyone else gone through this before. There is no space in IE6 or IE7. Thanks, teamhonda81 I can't seem to pin down why I have extra space to the right of my containing DIV on my home page. All of the sub-pages (similar page layout) render fine, but the home page displays a bunch of space to the right. Any ideas? You can see what I mean at www . deepwaterchurch . com I am working on a site and have found a problem that I can't explain on my own. I would like someone to look at this site: http://www.canada-training-group.ca and tell me why there is extra space at the top in IE but not in Firefox. Thanks, Timmy-d I'm having a weird quirk happening at the bottom of a page I am developing. There is extra space, maybe 80-100px of it, showing up at the bottom in my container div (which I have id'd as "reality"). Can anyone suggest what might be shoving all that extra space in there? html page: http://www.iainhamp.com/reality/hyborianwar.html css page:http://www.iainhamp.com/reality/reality_hyborian.css Thanks for any help you can provide. - iain I've been trying to setup a basic template for a site. In firefox I got it looking pretty good, but in IE there seems to be about 3 pixels of extra space to the left of the header image. The url is: http://igocity.aoeex.com/ If you look in firefox, you can see the black box where the login form is, and the banner image to the right of it are side-by-side with no space between them. This is what I want. In IE, there is about 3 pixels of white space between the login box and the banner image. This causes the image to drop down below the login box instead of it being beside it normally. For now, I've expanded the width of the outer div so they are side by side, but with the space. I can't figure out why this space is there, or how to get rid of it. Any suggestions? The HTML for the header looks like so: Code: <div id="headerDiv"> <div id="loginBox"> <form method="post" action="/login.php"> <input type="text" value="" class="txtUsername" name="txtUsername" /><br /> <input type="password" value="" class="txtPassword" name="txtPassword" /><br /> <a href="login_help.php" class="loginTroubleLink">>> login trouble?</a> <input type="submit" value="log in" name="btnLogin" class="btnLogin"/> </form> </div><img src="images/road_trip_banner.jpg" width="540" height="80" id="headerBannerImage"/> </div> CSS can be seen at: http://igocity.aoeex.com/css/template_css.css I was wondering if anyone knows how to get a space between blocks in a list. If you have list that have more that one line in a block it looks better to have gaps greater than the leading to separate them. I can't figure how to accomplish this, does anyone have any ideas. Hi, I am writing a code for form: Code: private name: <input size="10" name="private_name" type="text"> last name: <input size="10" name=last_name" type="text"> I want to increase the space between the two lines I tried to use the css line-height and it did increase the vertical space between the two lines. However only in the part of the words. In the case of the two input boxes instead of more space they become "taller", I can understand the logic behind this, what I don't know is a way to increase the vertical space between the two lines that will work in the case of the input boxes as well. How can I solve this? Thank in advance Simple layout but having issues with the left sidebar float aligning flush with the container next to it on top in IE. Works perfectly in FF of course. Here is the link to the page: http://www.kofc2332.org/new_site/ All help/suggestions/guidance is appreciated. |