CSS - Wrapper Background Not Longer (higher) Than Viewport
Similar TutorialsHi, I am currently redoing our website and have some basic layout lying around, but I just cannot find the reason for IEs behavior regarding the background image. I put a static version of the test page up on http://noitekk.de/test/ntk/index.html Everything looks fine in Opera and Firefox, but on IE (6 and 7) the background for the wrapper div is 1px off to the right, so the navigation bar and the header (which is all black ATM) look as if they are positioned badly. Anybody got any idea? Thanks Thomas Hey all, am working on this: http://www.trshady.com/beyondfootball/ And have a problem with the 'wrapper' div ( which holds all the divs on the page ). In Internet explorer the background and border show up fine, but for some reason the wrapper background only is a large in height as the top banner .. Check it in both browsers so you know what I mean. Have made the wrapper background pink so it stands out. Thanks My background image was coded properly? but not displaying in FF 2 or IE 7. background-image:url(../images/FFFFFF-bg780.gif) top left repeat-y; I posted this http://forums.devshed.com/css-help-116/background-image-not-displayed-449462.html Then I took a look at the Firefox error console and saw: Warning: Expected end of value for property but found 'top'. Error in parsing value for property 'background-image'. Declaration dropped. Source File: blah blah blah.css Line: 41 When I changed my CSS to this: background-image:url(../images/FFFFFF-bg780.gif); background-position: top left; background-repeat:repeat-y; everything works! I'm trying to get a background image/color to repeat down the left hand column of a site, he http:// www. lisaannschleipfer .com, but can't seem to get it working in either FF or IE. You'll notice that in the left hand column, the tannish color does not repeat all the way down the column. I'm fairly certain I've narrowed it down to the bit of CSS code he Code: div#wrapper { margin: auto; width:800px; background: #d1c8ab url(../images/wrapper_bg.jpg); background-repeat: repeat-y; } I've tried looking around the forum for some solutions, and have found a few possibilities (height: auto, overflow: auto, etc), but nothing that I have tried to insert into the stylesheet has seemed to work. Does anyone have any suggestions or solutions? I'd appreciate it! Here's the entire stylesheet, for reference: Code: html { height: 100%; margin-bottom: 0px; } form { margin: 0; padding: 0; } img,table { border:none; } table td { vertical-align:top; } body { font-family: Helvetica,Arial,sans-serif; line-height: 1.3em; margin: 0px 0px 0px 0px; font-size: 12px; color: #666666; background: #0d789c url(../images/bg.jpg) top center repeat-x; } a:link, a:visited { text-decoration: none; font-weight: normal; color: #0d789c; } a:hover { text-decoration: underline; font-weight: normal; color: #0d789c; } input.button { cursor: pointer; vertical-align: bottom; border: 0px; background:none; } p { margin-top: 0; margin-bottom: 5px; text-align:justify; } /*****************************************/ /*** Template specific layout elements ***/ /*****************************************/ #header { margin:0 auto; width:940px; } .left_bg { background: transparent url(../images/left_bg.jpg) top right no-repeat; width:70px; } .middle_bg { background: transparent url(../images/.jpg) top right no-repeat; width:800px; } .right_bg { background: transparent url(../images/right_bg.jpg) top left no-repeat; width:70px; } .top_bg { background: transparent url(../images/top_bg.jpg) top center no-repeat; width:800px; height:45px; } .rightside { background: transparent url(../images/rightside_bg.jpg) top center no-repeat; width:185px; height:173px; } .header_bg { background: transparent url(../images/header_bg.jpg) top center no-repeat; width:615px; height:173px; } #page_bg { padding: 0; margin:0px auto; } #top { width:800px; margin:0 auto; padding:0; } div.center { padding:0; } div#wrapper { margin: auto; width:800px; background: #d1c8ab url(../images/wrapper_bg.jpg); background-repeat: repeat-y; } #logo { padding:47px 50px 0 50px; height:100px; text-align:left; margin:0 auto; } #logo a, #logo a:link, #logo a:hover { font-weight: normal; font-family : "Trebuchet MS", Arial, Helvetica, sans-serif; font-size: 36px; padding:0px; margin:0; line-height:1.4em; letter-spacing:2px; color:#fefefe; text-decoration:none; } div.newsflash { height:150px; padding:10px; overflow: hidden; color:#fff; text-align:left; } div#tabarea { margin: 0; width:615px; height:26px; text-align:left; } #footer { width:800px; margin:0 auto; } .validation { float:right; padding:8px 20px 0 0; } #footer .footer { background: transparent url(../images/footer.jpg) top center no-repeat; height:28px; width:800px; } #pathway { padding: 0px 10px 8px; width: auto; margin-right: 250px; text-align: left; } #search { float: right; width:320px; margin-top: -20px; margin-right: 20px; height: 40px; overflow: hidden; text-align:right; } #area { padding: 0; width:100%; /* color:#d1c8ab; */ } #whitebox { margin: 0; width: auto; } #whitebox div { text-align: left; } #whitebox_br { height: 13px; background: url(../images/mw_content_b_r.png) 100% 100% no-repeat; } /* horizontal pill menu */ .pill { margin:0px 0 0 1px; text-align:left; } td.pill_m { padding: 0; margin: 0 10px; width: auto; text-align:center; } #pillmenu { white-space: nowrap; height: 26px; float: left; } #pillmenu ul { margin: 0; padding: 0; list-style:none; } #pillmenu li { float: left; margin: 0px 1px 0 0; padding: 0; background: transparent; } #pillmenu a { font-family: Arial, Helvetica, sans-serif; font-size: 11px; font-weight: normal; float:left; display:block; height: 24px; line-height: 24px; padding: 2px 10px 0 10px; color: #fff; text-decoration: none; background: transparent; } #pillmenu a:hover { text-decoration: underline; } #pillmenu a#active_menu-nav { color: #fff; background: url(../images/active_arrow.gif) top center no-repeat; } #pillmenu a#active_menu-nav:hover { color: #fff; } #leftcolumn { margin: 0; text-align:left; width: 221px; float:left; background: #d1c8ab url(../images/leftcol_bg.jpg) top left no-repeat; } div#maincolumnfull { padding:2px 10px; float:left; width: 760px; } div#maincolumn { padding:20px 10px; float:left; width: 559px; background: #ffffff url(../images/maincol_bg.jpg) top left no-repeat; } div.nopad { padding: 0; text-align:left; } td.middle_pad { width: 20px; } /*****************************************/ /*** Joomla! specific content elements ***/ /*****************************************/ div.offline { background: #fffebb; width: 100%; position: absolute; top: 0; left: 0; font-size: 1.2em; padding: 5px; } span.pathway { display: block; margin: 0 20px; height: 16px; line-height: 16px; overflow: hidden; } /* headers */ div.componentheading { padding-left: 0px; } h1 { padding: 0; font-family:Helvetica ,Arial,sans-serif; font-size: 1.3em; font-weight: bold; vertical-align: bottom; color: #666; text-align: left; width: 100%; } h2, .contentheading { padding: 0; font-family: Tahoma, Helvetica,sans-serif; font-size: 12px; font-weight: bold; vertical-align: bottom; color: #8cb6cf; text-align: left; width: 100%; } table.contentpaneopen h3 { margin-top: 25px; } h4 { font-family: Arial, Helvetica, sans-serif; color: #333; } h3, .componentheading, table.moduletable th, legend { margin: 0; font-weight: bold; font-family: Tahoma,Helvetica,Arial,sans-serif; color:#71a7c8; font-size: 1.4em; padding-left: 0px; margin-bottom: 10px; text-align: left; } /* small text */ .small { font-size: .90em; color: #999; font-weight: normal; text-align: left; } .modifydate { height: 20px; vertical-align: bottom; font-size: .90em; color: #999; font-weight: normal; text-align: left; } .createdate { height: 20px; vertical-align: top; font-size: .90em; color: #999; font-weight: normal; vertical-align: top; padding-bottom: 5px; padding-top: 0px; } a.readon { margin-top: 10px; display: block; float: left; background: url(../images/mw_readon.png) top right no-repeat; padding-right: 20px; line-height: 14px; height: 16px; } /* form validation */ .invalid { border-color: #ff0000; } label.invalid { color: #ff0000; } /** overlib **/ .ol-foreground { background-color: #f6f6f6; } .ol-background { background-color: #666; } .ol-textfont { font-family: Arial, Helvetica, sans-serif; font-size: 10px; } .ol-captionfont { font-family: Arial, Helvetica, sans-serif; font-size: 12px; color: #f6f6f6; font-weight: bold; } .ol-captionfont a { color: #0B55C4; text-decoration: none; font-size: 12px; } .ol-closefont {} /* menu links */ a.mainlevel:link, a.mainlevel:visited { padding-left: 5px; } a.mainlevel:hover { } /* spacers */ span.article_separator { display: block; height: 20px; } .article_column { padding-right: 5px; } .column_separator { border-left: 1px dashed #e0e0e0; padding-left: 10px; } td.buttonheading { } .clr { clear: both; } div#maindivider { border-top: 1px solid #ddd; margin-bottom: 10px; overflow: hidden; height: 1px; } table.blog span.article_separator { display: block; height: 20px; } /* table of contents */ table.contenttoc { margin: 5px; border: 1px solid #ccc; padding: 5px; } table.contenttoc td { padding: 0 5px; } /* content tables */ td.sectiontableheader { background:transparent url(../images/sectiontableheader_bg.gif) top left repeat-x; color: #fff; font-weight: bold; padding: 4px; border-right: 1px solid #fff; } tr.sectiontableentry0 td, tr.sectiontableentry1 td, tr.sectiontableentry2 td { padding: 6px; } td.sectiontableentry0, td.sectiontableentry1, td.sectiontableentry2 { padding: 3px; } tr.sectiontableentry1 { background:#f3f3f3; } tr.sectiontableentry2 { background:#fefefe; } /* content styles */ table.contentpaneopen, table.contentpane { margin: 0; padding: 0; } table.contentpaneopen li { margin-bottom: 5px; } table.contentpaneopen fieldset { border: 0; border-top: 1px solid #ddd; } table.contentpaneopen h3 { margin-top: 25px; } table.contentpaneopen h4 { font-family: Arial, Helvetica, sans-serif; color: #333; } .highlight { background-color: #fffebb; } /* module control elements */ table.user1user2 div.moduletable { margin-bottom: 0px; } div.moduletable { margin-bottom: 25px; } div.module_menu, div.module { margin: 0 0 0 2px; padding: 0; margin-bottom: 15px; } div.module_menu div div div div ,div.module div div div div { background: none; padding: 0; } div.module_menu div, div.module div { } div.module_menu div div, div.module div div { padding:0 0 10px 0; } div.module_menu div div div, div.module div div div { padding: 0px; width: auto; } div.module_menu ul li a:link, div.module_menu ul li a:visited, div.module ul li a:link, div.module ul li a:visited { font-weight: normal; background:transparent url(../images/blue/bullet2.jpg) top left no-repeat; line-height:24px; } #leftcolumn div.module table ,#rightcolumn div.module table { width: auto; } #leftcolumn h3, #rightcolumn h3 { height:36px; color:#fff; font-weight: bold; font-family: Tahoma, Helvetica,Arial,sans-serif; font-size: 12px; line-height:26px; margin: -2px 0 0 ; position:absolude; padding:0px 0 2px 22px; text-align: left; width:198px; background:transparent url(../images/h3_bg.gif) top left no-repeat; } #leftcolumn .moduletable_menu, #leftcolumn .moduletable, #leftcolumn .moduletable_text, #leftcolumn .c { margin:0 0 20px 0; padding: 0px; text-align:left; } #leftcolumn ul.menu, #rightcolumn ul.menu { margin:0; padding:0px 0 0 10px; list-style:none; margin: 0px 0; width:194px; } #leftcolumn ul.menu li, #rightcolumn ul.menu li { margin:0; padding:0; } #leftcolumn ul.menu li a, #leftcolumn ul.menu li a:link, #rightcolumn ul.menu li a, #rightcolumn ul.menu li a:link { display:block; line-height:20px; border-bottom:1px dotted #c3b586; padding:2px 0px 0 12px; height:20px; text-decoration:none; text-align:left; color:#666666; } #leftcolumn ul.menu li a:hover, #rightcolumn ul.menu li a:hover { color:#0d789c; } /* ****** left col current menu ****** */ #leftcolumn ul.menu li#current a, #leftcolumn ul.menu li#current a:link, #rightcolumn ul.menu li#current a, #rightcolumn ul.menu li#current a:link { display:block; line-height:20px; border-bottom:1px dotted #0d789c; padding:2px 0px 0 12px; text-decoration:none; color:#0d789c; } #leftcolumn ul.menu li#current a:hover, #rightcolumn ul.menu li#current a:hover { color:#666666; } /* ****** left col sub menu ****** */ #leftcolumn ul.menu li ul, #rightcolumn ul.menu li ul { margin:0; padding:0 0 0 0px; list-style:none; } #leftcolumn ul.menu li#current ul li a, #leftcolumn ul.menu li#current ul li a:link, #rightcolumn ul.menu li#current ul li a, #rightcolumn ul.menu li#current ul li a:link { background: transparent url(../images/menu_sub_link_bg.gif) left no-repeat; text-decoration:none; color:#666666; padding:2px 25px; } #leftcolumn ul.menu li.active ul li#current a, #leftcolumn ul.menu li.active ul li#current a a:link { background: transparent url(../images/current_link.jpg) left no-repeat; text-decoration:none; color:#666666; padding:2px 25px; } #leftcolumn ul.menu li#current ul li a:hover, #rightcolumn ul.menu li#current ul li a:hover { s/menu_sub_link_bg.gif) left no-repeat; color:#666666; } /* forms */ #leftcolumn .moduletable ul, #rightcolumn .moduletable ul { margin:6px 0; padding:0; list-style:none; } #leftcolumn .moduletable ul li, #rightcolumn .moduletable ul li { margin:0; padding:0 2px; } table.adminform textarea { width: 540px; height: 400px; font-size: 1em; color: #000099; } div.search input { width: 69px; vertical-align:bottom; background-color: #ffffff; margin: 15px 0 10px 0; } form#form-login fieldset { margin:0px 20px 0 20px; padding:20px 0 0 0; border:none; text-align:left; } form#form-login ul { text-align:left; list-style:none; margin:10px 0 0 0; padding:0; } form#form-login ul li{ text-align:left; margin:0; padding:0 0 0 20px; } #leftcolumn div.module h3 { top:-500px; left:-500px; padding-left:0; position:absolute; } /* thumbnails */ div.mosimage { margin: 5px; } div.mosimage_caption { font-size: .90em; color: #666; } div.caption { padding: 0 10px 0 10px; } div.caption img { border: 1px solid #CCC; } div.caption p { font-size: .90em; color: #666; text-align: center; } /* Parameter Table */ table.paramlist { margin-top: 5px; } table.paramlist td.paramlist_key { width: 128px; text-align: left; height: 30px; } table.paramlist td.paramlist_value { } div.message { font-family : "Trebuchet MS", Arial, Helvetica, sans-serif; font-weight: bold; font-size : 14px; color : #c30; text-align: center; width: auto; background-color: #f9f9f9; border: solid 1px #d5d5d5; margin: 3px 0px 10px; padding: 3px 20px; } /* Banners module */ /* Default skyscraper style */ .bannergroup { } .banneritem { } /* Text advert style */ .banneritem_text { padding: 4px; font-size: 11px; } .bannerfooter_text { padding: 4px; font-size: 11px; background-color: #F7F7F7; text-align: right; } /* System Messages */ /* see system general.css */ .pagination span { padding: 2px; } .pagination a { padding: 2px; } /* Polls */ .pollstableborder td { text-align: left; } /* Frontend Editing*/ fieldset { border: 1px solid #ccc; margin-top: 15px; padding: 0 15px; } legend { margin: 0; padding: 0 10px; } td.key { border-bottom:1px solid #eee; color: #666; } /* Tooltips */ .tool-tip { float: left; background: #ffc; border: 1px solid #D4D5AA; padding: 5px; max-width: 200px; } .tool-title { padding: 0; margin: 0; font-size: 100%; font-weight: bold; margin-top: -15px; padding-top: 15px; padding-bottom: 5px; background: url(../../system/images/selector-arrow.png) no-repeat; } .tool-text { font-size: 100%; margin: 0; } /* System Standard Messages */ #system-message dd.message ul { background: #C3D2E5 url(../../images/notice-info.png) 4px center no-repeat;} /* System Error Messages */ #system-message dd.error ul { color: #c00; background: #E6C0C0 url(../../system/images/notice-alert.png) 4px center no-repeat; border-top: 3px solid #DE7A7B; border-bottom: 3px solid #DE7A7B;} /* System Notice Messages */ #system-message dd.notice ul { color: #c00; background: #EFE7B8 url(../../system/images/notice-note.png) 4px center no-repeat; border-top: 3px solid #F0DC7E; border-bottom: 3px solid #F0DC7E;} /* ****************************************************************************** */ /* blue */ input,button { background:transparent; vertical-align:bottom; } input[type="checkbox"], input[type="radio"]{ background: transparent; border: none; } /* -------------------------- */ a.sgfooter:link, a.sgfooter:visited { color : #fff; font-family: Arial,sans-serif; text-decoration:none; } a.sgfooter:hover { color: #fff; font-family: Arial,sans-serif; text-decoration:none; } #sgf { font-size: 11px; text-align:left; color: #fff; padding:4px 0 0 10px ; font-family: Arial,sans-serif; width:500px; float:left; } .sgf { text-align:right; font-size: 11px; font-family: Arial,sans-serif; color: #666; text-decoration:none; } .sgf1 { font-size: 11px; font-family: Arial,sans-serif; color: #666666; text-align:left; } a.sglink:link, a.sglink:visited { color : #666666; font-size : 11px; font-family: Arial,sans-serif; text-decoration:none; } a.sglink:hover { color : #666666; font-family: Arial,sans-serif; text-decoration:none; } I have some tables that contain a lot of columns, so the table goes beyond the users viewport. I would like the body of the page to expand to the table, anyone know of a way to get the body to expand horizontally. Below is some code, I would like the red outline to expand to the black. Code: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> <title>Insert title here</title> </head> <body style="border:1px solid red;"> <table style="border:1px solid green;width:2500px;"> <tr> <td style="">slkfdj</td> </tr> </table> </body> </html> I've been searching for a few days, but I haven't found a solution to my problem. How do I get my parent DIV to expand to contain all of my content beyond the viewport? CSS: Code: html { margin: 0px; padding: 0px; height: 100%; width: 100%; min-height: 100%; } body { margin: 0px; padding: 0px; height: 100%; width: 100%; min-height: 100%; } .page { background-color: #dddddd; margin-left: -390px; border-top-width: thin; border-right-width: thin; border-bottom-width: thin; border-left-width: thin; border-right-style: solid; border-left-style: solid; border-top-color: #9CB0C0; border-right-color: #9CB0C0; border-bottom-color: #9CB0C0; border-left-color: #9CB0C0; position: absolute; height: 100%; min-height: 100%; width: 780px; left: 50%; top: 0; } .header { position: absolute; height: 158px; width: 764px; background-color: #FFFFFF; left: 7px; top: 0px; } .content { position: absolute; left: 7px; top: 159px; background-color: #9CB0C0; height: 821px; width: 764px; margin-bottom: 34px; } .footer { background-color: #415569; height: 34px; width: 764px; left: 7px; bottom: 0px; } And the HTML: Code: <?xml version="1.0" encoding="iso-8859-1"?> <!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> <title>Untitled Document</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <link href="/test.css" rel="stylesheet" type="text/css" /> <script language="JavaScript" type="text/JavaScript"> <!-- function MM_reloadPage(init) { //reloads the window if Nav4 resized if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) { document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }} else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload(); } MM_reloadPage(true); //--> </script> </head> <body> <div id="lPage" style="position:absolute; z-index:1" class="page"> <div id="lContent" style="position:absolute; z-index:2;" class="content"></div> <div id="lHeader" style="position:absolute; z-index:1" class="header"></div> <div id="lfooter" style="position:absolute; z-index:3" class="footer"></div> </div> </body> </html> I've searched through a few of the threads here, but haven't been able to find an answer either. Thanks, Brent Greetings, I'm trying to implement a pseudo-modal dialog by layering the following: A div containing an iframe to be loaded with a form page A semi-transparent div to cover the entire underlying page, to prevent clicks on other elements The problem is that the cover div is only as tall as the viewport, which means that any page content in the scroll area below the viewport is left exposed. Below is the source. Any suggestions would be most appreciated! Code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html> <head> <meta http-equiv="content-type" content="text/html;charset=iso-8859-1"> <title>Test</title> <style type="TEXT/CSS"> html,body { margin:0; padding:0; height:100%; } #contactDiv{ z-index:2; display:none; position:absolute; top:100px; left: 50%; margin-left:-300px; border-style:solid; height:450px; width:600px; background-color:#ffffff; border-color:#666666; border-width:10px; } #modalOverlay{ z-index:1; display:none; position:absolute; top:0px; left: 50%; width:1008px; margin-left:-505px; min-height:100%; background-color:#000000; filter: alpha(opacity=30); -moz-opacity: 0.3; -khtml-opacity: 0.3; opacity: 0.3; } </style> </head> <body> <a onclick= "javascript:document.getElementById('modalOverlay').style.display='block'; document.getElementById('contactDiv').style.display='block';"> SHOW IT</a> <p> <div id=contactDiv> <iframe id=contactIframe width=600 height=450 scrolling="no" frameborder=0></iframe> </div> <div id=modalOverlay> </div> testing testing testing testing testing testing testing testing (The word "testing" was actually repeated multiple times -- enough to force scrolling on my laptop. I edited it for (relative) brevity.) </body> </html> This is a simplified version of the actual page. There's a menubar with a link that populates the div with the actual contact form. I cut out everything that didn't relate to the problem. Thanks, DM is it possible? its the banner... the content spans around 1000 pixels wide so with 100% width i miss a piece when i scroll to right of page just making the body around 1000 pixels seems to get a horizontal scrollbar when its not needed for the content....either that or its just missing some pixels... cant a div be 100% of the page? I've got a problematic background DIV. It fills up the entire viewport and looks correct, but cuts off at the bottom (one screen height down) when I scroll. How can I get this DIV to span the entire height of the document, instead of just the height of the viewport? BTW, it works fine in IE 6, but cuts off in FireFox 0.9, Opera 7.5, and Netscape 7.1 Here's the code (you'll have to populate the content DIV to get scrollbars and witness the problem): Code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <style type="text/css"> <!-- body { margin: 0; padding: 0; height: 100%; background-color: #F1EFE2; } html { margin: 0; padding: 0; height: 100%; } .bg { position: relative; margin-top: 0px; margin-left: auto; margin-right: auto; margin-bottom: 0px; width: 960px; height: 100%; background: #F7F6EF; text-align: center; border-right-color: #9E987F; border-right-width: 1px; border-right-style: solid; border-left-width: 1px; border-left-style: solid; border-left-color: #9E987F; } .heading { position: relative; margin-top: 0px; margin-left: 0px; margin-right: 0px; width: 100%; background: #7C2812; color: #F7F6EF; vertical-align: middle; text-align:left; padding-top: 10px; padding-bottom: 10px; text-indent: 10px; } .content { position: relative; top: 20px; padding-left: 15px; padding-right: 15px; width: 920px; vertical-align: top; text-align:left; } --> </style> </head> <body onResize="window.location.href = window.location.href;"> <div class="bg"> <div class="heading"> heading goes here </div> <div class="content"> content goes here </div> </div> </body> </html> Any help would be greatly appreciated! I have created a CSS site that has a footer spanning the bottom of the viewport and whilst I have managed to glue it to the bottom I have another div that is behind it even though I think I have set-up the container properly. The troublesome page is http://www.cimbian.co.uk/BognorArchers/recurve.htm and you will see that the bottom of the text in the main pane is obscured by the footer. Basically I have a meta-wrapper for the whole page: and then have the main content within it. Following on from the content I have the footer and then I close the meta-wrapper. Something like this: <div id="meta_wrapper"> <div id="BA_main_content_area" class="clearfix"> <div id="BA_Main_Full_Width"> </div> <div id="footer"> </div> </div> My CSS for this is: div#meta_wrapper { width: 760px; margin-left: auto; margin-right: auto; background-color: yellowgreen; text-align: left; position: relative; min-height: 100%; height: 100%; voice-family: "\"}\""; voice-family: inherit; } html>body #meta_wrapper { height: auto; } div#BA_main_content_area {width:760px; align: center; margin-top: 0; margin-right: 0; margin-bottom: 0; margin-left: 0; font-size: 0.85em } div#BA_Main_Full_Width { border:3px inset yellow; font-family: Verdana; font-size: 0.85em; text-align: justify; position: relative; width: 500px; margin: 10px 30px 0px 10px; padding: 3px; background-color: #FFFFCC; float: left; } div#footer { position: absolute; bottom: 0; width:760px; padding:4px 0; font-size: 0.6em; text-align: center; background-color: white; /* Blue */ border-top:1px solid yellow; border-bottom:2px solid yellow; margin-top:1.5em;} /* orange border */ The problem occurs in IE and in Netscape so although I have box-model problems due to IE in Firefox the problem is not limited to IE. As far as I can tell from much web-reading and a couple of books this should do it. Any thoughts? PS: I also posted this in the MS FP forum as I built the page in FP but have not yet found a solution so please don't yell if you have seen the post there too ;-) At first this was slightly amusing. The border in the lower middle column dubbed "News" extended underneath the other divs to the top in Firefox. See he www.djoj.net/test/indexwierd.html Css: (Look at the way bottom of the CSS. The last 3 styles) www.djoj.net/test/styles2.css So I changed my div's to span's and wrapped them in one div labled "bottom" Now look... www.djoj.net/test/index.html Css: (once again, at the bottom) www.djoj.net/test/styles.css How can I fix this? It's a problem in both browsers. I don't want to use tables, I'd rather stick to CSS positioning. Thank you in advance! ~B My problem is that the site I'm developing for my church displays wonderfully in FireFox Opera Netscape BUT in IE the headings in the content block refuse to be transparent so that my background image shines through like it does for the rest of that block. Here's the page...any help would be appreciated much! Parkview Baptist Church I just noticed that if I resize the IE to a real narrow window, it stacks the first h2 and pushes the background down enough that all of that first h2 shows, but the subsequent on is not visible. Don't know if that helps or not... Best Regards, Jim I would rather be exposed to the inconveniences attending too much liberty than to those attending too small a degree of it. -- Thomas Jefferson So I'm working on a website of mine that needs a varying amount of content boxes (divs with content in) per page. The way I want them to display however, is the catch. So I'll explain what I want first, and then show what I've done at the moment. What I want I want them to display at around 10% from the bottom of the user's page. And be anchored to that point. So no matter what size the browser window is, the content will be fairly similarly laid out (within reason). SO. If a page needs only one content box (one div with content in), I want the bottom left corner of that div to be 10% up the users browser window from the bottom of the page. BUT. Then if I want 2 divs of content on that page, I want the 1st div to be pushed up the page by the 2nd, and have the 2nd div's bottom left corner 10% up the user's page. And then with the same pattern every time I add another div. So to try and make sure you get it, I drew these. On a page that needs 1 content box - http://img163.imageshack.us/img163/945/1div.jpg On a page that needs 2 content boxes - http://img715.imageshack.us/img715/33/2divs.jpg On a page that needs 3 content boxes - http://img693.imageshack.us/img693/1484/3divs.jpg So what I've done Is.. used a container div that is situated at that point of the page that I want the divs to align from. But because I failed at trying to relatively position them, I just positioned them with absolute values. Which is far too rigid for what I need. At the moment it has 3 divs to show the process I want. The 1st content div obviously then has to stay at the bottom, so I need to move my content to other divs when I want to add something below an existing one. Another problem/requirement is that if one of the divs has more lines of content than the other, big inconsistent gaps emerge. So depending on the size of the div, it would need to get pushed further, or less, up the page. HTML Code: <div id="content-container"> <div id="content1"> abc </div> <div id="content2"> def </div> <div id="content3"> ghi </div> </div> CSS Code: #content-container { width: 1px; height: 1px; position: absolute; bottom: 10%; left: 10%; } #content1 { width: 600px; height: 10px; position: absolute; bottom: 110px; } #content2 { width: 600px; height: 10px; position: absolute; bottom: 250px; } #content3 { width: 600px; height: 10px; position: absolute; bottom: 390px; } Basically I want it to be flexible, rather than rigid. Which I had hoped could be fixed with relative positioning, but I couldnt manage that. Has anyone heard of Firefox 4 or Firefox 3.5 positioning a Div 3 pixels higher on a web page than all other A-Grade browsers? If you want to see what I mean, go to baampblue . asystechonline . com / ReconstructIndex.php. Sorry I could not insert a link. I'm a new member. I password protected this to keep bots from scanning it. The username is the word demo. The password is also the word demo. Look for "Carl Gohm" on the right side of the page, under "BAAMP Honors Lifetime Members". Click on the Carl Gohm link. A new rounded corner box will open up in the "Featured Projects" display with a picture and information about Carl. If you look at the new box in IE 8, Opera 11, Chrome 11, or Safari 5.0.5 the new box fits perfectly inside of the Featured Projects display. If you look at the new box in Firefox 4 or 3.5, you should notice that the new box is shifted up 3 pixels too high. The HTML and CSS validate with no errors on the W3C validators. I'm using jQuery to generate the new box for Carl Gohm. I have ruled out the jQuery as the cause of the problem by creating a minimal test case that doesn't involve jQuery. I tried using a clean version of Firefox from Spoon.net, because I thought maybe one of the Add-Ons in Firefox was causing the problem. That didn't make any difference. I tried viewing this on another computer that is running Firefox 4 on Windows XP, but the problem was still there. I used Firebug to disable and then re-enable each line of CSS one at a time to see if there was a CSS problem. I didn't notice an improvement. I just need to know if I am wasting my time trying to troubleshoot something that is not correctable. Thank you in advance for your time. hey all, i have a very wierd problem! Im no CSS guru but i thought i could get this right i have two divs that should both be 100% so i have set them to width:100% BUT....in both Moz FF and IE there is a difference... it is less noticable in IE than in FF but still, not great and kinda wierd!! can anyone adise me please? here is the code Code: #TitleBar { position:absolute; top: 0px; left: 0px; /*margin: 0px 0px 10px 0px;*/ padding: 0px 0px 0px 0px; padding-left:10px; width:100%; /* For IE5/Win's benefit height = [correct height] + [top padding] + [top and bottom border widths] */ height:170px; /* 14px + 17px + 2px = 33px */ border-style:solid; border-color: #A4AA54; border-top: 1px #A4AA54 solid; border-bottom: 1px #A4AA54 solid; border-width:1px 1px; /* top and bottom borders: 1px; left and right borders: 0px */ background-color:#A4AA54; background-image:url(../images/logo/gglogo.JPG); background-position: 1% 2px; background-repeat:no-repeat; z-index:0; /* This is a fix for IE% */ voice-family: "\"}\""; voice-family:inherit; height:170px; width:100%; /* the correct height */ } /* "be nice to Opera 5" */ body>#TitleBar {height:170px; width:100%;} #MenuBar { position:absolute; top: 137px; left:0px; width:100%; padding:15px; background-color:#667138; border-bottom:1px solid #A4AA54; line-height:17px; z-index:1; /* Again, the ugly brilliant hack. */ voice-family: "\"}\""; voice-family:inherit; } /* Again, "be nice to Opera 5". */ body>#MenuBar {width:100%;} thanks in advanced RF My site can be seen he pioneer.nic.edu/~mdmoffet/index.html The CSS is located at pioneer.nic.edu/~mdmoffet/church.css The problem is pretty apparent if you look at the page - the text flows down and beyond the div it is in, and the background/border of the div just randomly stops. I've put height:100% and min-height:100% in all parent elements for it, but that doesn't seem to be working as I expected it to. I'm honestly not sure what to do at this point - if the text is less than the viewport, the div will cover the full length like it is supposed to, it just seems to break at a certain length. Both my html and my css validate. Any ideas? Hi, I'm pretty new to this so not 100% sure what I'm talking about. I'm trying to complete a university project, in order to do so I have to move images using a style sheet and have done so successfully so far but today when trying to move my rollovers the stylesheet didnt move my images. Previous images I moved worked but the new ones dont. Any help would be greatly appreciated! Thanks! As box1 is filled with content I need box 2 & 3 to stretch to the same height, and so on for box 2 & 3. view page: http://www.franklandmedia.com/test <html> <head> <title>nothin</title> <style type="text/css"> <!-- body { text-align: center; margin: 0px; padding: 0px; min-width:780px; /* stop mozilla sliding off the edge */ } .central { margin-right: auto; margin-left: auto; position: relative; width: 780px; text-align: left; } #container { float: none; margin: 0 auto; width: 780px; text-align: left; } #top { float: left; width: 780px; background-color: #DDD; } #navbar { float: left; width: 780px; background-color: #EEE; } #middle { float: left; width: 780px; } #footerblock { float: left; width: 780px; background-color: #666; } #box1, #box2, #box3 { float: left; width: 260px; } #box1 { background-color: #AAA; } #box2 { background-color: #BBB; } #box3 { background-color: #CCC; } --> </style> </head> <body><div class="central"> <!--*******page content start*******--> <div id="container"> <div id="top">top</div> <div id="navbar">navbar</div> <div id="middle"> <div id="box1">box1<br>box1<br>box1</div> <div id="box2">box2</div> <div id="box3">box3</div> </div> <div id="footerblock">footer</div> </div> <!--*******page content end*******--> </div></body></html> Hi, My website is deployed at www.wecook.co.uk and i'm having problems with the gray background - i want it to be at least as long as the users page(without specifying a height) - how can i do this? the stylesheet can be seen at www.wecook.co.uk/wecook/wecook.css Any help is appreciated. Thanks in Dreamweaver, how do I change alignment of e.g subNavColumn div tag within wrapper Div Tag, I wish to align subNavColumn on left of page. Banner and NavBar extend across full page. I have been unable highlight layer to change properties, must a CSS Stylesheet be attached at outset, could this be part of my problem. Also how can I remove gap showing between layers in IE. I wish to contain all div tags together, Would appreciate help. |