CSS - Overflow Content In Ie
I currently have a drop down menu on a sidebar that when you roll over the buttons(each its own list item) a drop down menu appears over top of the buttons underneath the one your mouse is on. This works fine in Firefox of course but in IE the drop down menu goes underneath the other buttons. Any suggestions how to fix this?
Similar TutorialsDear all, IE problems trying to get a large amount of content to sit in a smaller div with overflow set to auto. In FF it works perfectly, but in IE the outer div ignores the width value I have set and instead expands to the width of the content. My code: Code: <div id="calendarWrapper" style="width:800px;height:600px;overflow:scroll;"> <div style="width:4000px;height:1000px;overflow:auto;background-image:url(img/calendarBackground.gif);position:relative"> <div style="background-color:#FFFFCC;position:absolute;top:76px;left:150px;width:1000px;height:74px;">Test</div> <div style="background-color:#FFFFCC;position:absolute;top:151px;left:300px;width:750px;height:74px;">Test</div> <div style="background-color:#FFFFCC;position:absolute;top:1px;left:75px;width:100px;height:74px;">Test</div> </div> </div> I found a couple more threads similar to this but none with a solution. any help most appreciated. Mark I have a layer 'main' that contains two columns - one on the left called 'left', one on the right called 'right'. Both columns are layers themselves. 'main' has a background colour 'left' and 'right' have a fixed size background image which does not repeat. JavaScript determines the size of the window and then sets the height of these three layers exactly. This is supposed to be a minimum height to ensure the page is filled initially, however I have used the following code (explained later): Code: if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) { myHeight = document.documentElement.clientHeight; } else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) { myHeight = document.body.clientHeight; } // main height var pageHeight = myHeight; document.getElementById("main").style.height = pageHeight+"px"; // content height var leftHeight = pageHeight - 233; document.getElementById("left").style.height = leftHeight+"px"; document.getElementById("right").style.height = leftHeight+"px"; Content on 'right' may extend beyond the height of the page and therefore makes the page scroll. When the content in 'right' expands - it is hoped that the size of 'main' expands so that the background colour of this layer fills the space where the content overflows. Using the above JavaScript and this HTML - that works as desired in IE7. Code: <div id="main" style="position: relative; margin: 0 auto; width: 680px; background: #E1E6EA; text-align: left; padding: 0; z-index: 2"> <div id="left" style="float: left; text-align: center; margin: 0; padding: 0; width: 198px; background: #E1E6EA; background-image: url('images/left.jpg'); background-repeat: no-repeat; z-index: 3"> blah </div> <div id="right" style="float: right; text-align: center; margin: 0; padding: 0; width: 482px; background: #E1E6EA; background-image: url('images/right.jpg'); background-repeat: repeat-x; z-index: 3; overflow: inherit"> badly coded extra bit to extend the layer <br><br><br><br><br><br> gfdgf <br><br><br><br><br><br><br><br><br> gfgf <br><br><br><br>yhyuyuy <br><br><br><br><br><br> gfdgf <br><br><br><br><br><br><br><br><br> gfgf <br><br><br><br>yhyuyuy </div> </div> As the content of 'right' expands so does the background behind everything. HOWEVER - this only works in IE and not the other two test browsers: Safari and Firefox. To remedy this - I tried minHeight instead of height. The outcome of that - the background behind 'right' extends (because the background colour continues past the minHeight) but the background behind 'left' is just not shown and the background of 'main' does not extent. Therefore it has a background on the left hand side until the minHeight of 'main' then the left hand side has no background after that point. That's in Firefox and Safari. With this "solution" in IE - it goes a bit weird but since it doesn't even work right in the other two I ignore that for now. So - it either works in IE or not at all. Hence why I am currently using the code that at least works in a browser. Any suggestions to get it working in all? Hi everyone. I recently redesigned my website and while it looks great in firefox, I'm having huge problems in IE 6.0. I have several pages with >50 thumbnails, and whenever these pages load in IE, scrollbars appear to the right and bottom of the div and quickly move by themselves to the upper left hand corner of the screen as the thumbnails load, shrinking the content into a little box of nothing in the upper left hand corner. The link to the site is in my profile, I am not allowed to post a url here since I'm new. The main page of the site is fine, but any of the links at the left will cause the problem because of all the thumbnails. I have been using "Group Photos" as the page to test. I am still a newbie at CSS and got this template for free and have tweaked it a bit. It came with an IE hack ("fix.css") that maybe isn't working properly. This is the IE hack: Code: html {overflow:hidden;} body {height:100%; width:100%; overflow:auto;} Here is the relevant code from my main stylesheet ("eyecandy.css"): Code: #sidebar {position:absolute; top:0; left:0; width:220px; height:100%; overflow:auto; background:#e0e0e0; text-align:right;} body > #sidebar {position:fixed;} #menu a {display:block; width:202px; padding:2px 18px 3px 0; color:#606060; background:#e0e0e0; font-size:1.1em; font-weight:normal; text-decoration:none; letter-spacing:-1px;} #content {width:685px; margin:0 0 0 240px; padding:20px 0; background:#fafafa;} Can anyone help? I hate I can't even post a link to the site directly or even the css file to make it easier. Both the CSS files I named are in the parent directory if you want to see them. Hi Could someone tell me why the content is not showing in Netscape 7 please This is the site http://www.hardingscatering.co.uk/06/index.htm I have put an overflow property on the container div, so FF can show white as the bground colour. But when viewed in Netscape the content is not there and on other pages a scroll bar appears. I always have trouble with this, and would really like to know what I am doing wrong. Thanks for any help. My CSS works in IE and Mozilla but not Netscape or Opera I have a 2 column website, built with 2 relative position DIVs, with overflow set to auto. Because of this, I turned off overflow on the body tag and on the html tag (overflow: hidden;). I didn't want to have 2 scroll bars on the right side of the window. When I first tested this on 4 browsers, IE, Mozilla, Netscape and Opera, it worked great, only having one scroll bar on the right side of the window when the page was longer than the window height. But when I moved to a new host server recently, I discovered that Netscape and Opera stopped working. They now simply give me blank screens. When I remove the "overflow: hidden;" specifications from the body tag and the HTML tag in my CSS file, Netscape and Opera once again display my web pages. However, now I get 2 scrollbars on the right side of all 4 browsers (in IE, the second scrollbar isn't actually there, but the space holder for the scrollbar is there). Is there a cross browser way for doing what I'm trying to do? Or am I faced with detecting the browser type on the server-side, and setting the style sheet appropriately? Here are the related parts of my CSS: /* CSS styles */ BODY { font-family : Verdana, Arial, Helvetica, sans-serif ; font-size : 10pt; background : Black; color : White; margin: 0; padding: 0; border-width: 0; overflow: hidden; } HTML { overflow: hidden; } #LeftNavDIV { position:relative; width:185px; height:100%; float:left; padding:2px 0px 0px 0px; margin:0px 0px 0px 0px; border:1px solid white; overflow:auto; } #ContentDIV { position:relative; height:100%; width:75%; float:right; padding:0px 0px 0px 0px; margin:0px 0px 0px 0px; border:0px dashed #336699; overflow:auto; } Hi there, I have a content glider script, but I have added it to a wrapper with a background image. The css is using a white background colour so when a new layer is glided up, it covers the one underneath it. However, I want the background to be transparent to show the background image underneath.... If I remove the white background, they layers become transparent and overlay each other, so you can see all text in the layers on top of each other making it impossible to read. Is there anyway I can make it so it has a transparent background, but so it will not show the content under the new slide? This is my CSS: PHP Code: .glidecontentwrapper{ position: relative; /* Do not change this value */ height: 230px; /* Set height to be able to contain height of largest content shown*/ overflow: hidden; } /* Total wrapper width: 350px+5px+5px=360px Or width of wrapper div itself plus any left and right CSS border and padding Adjust related containers below according to comments */ .glidecontent{ /*style for each glide content DIV within wrapper.*/ position: absolute; /* Do not change this value */ background: white; visibility: hidden; width: 330px; } /* Total glidecontent width: 330px+10px+10px=350px Or width of wrapper div itself (not counting wrapper border/padding) */ .glidecontenttoggler{ /*style for DIV used to contain toggler links. */ width: 360px; margin-top: 6px; text-align: center; /*How to align pagination links: "left", "center", or "right" background: white; /*always declare an explicit background color for fade effect to properly render in IE*/ } Any help would be great! Thanks. My page looks decent in Firefox but in IE the overflow property doesn't seem to be working. Perhaps you can give me some pointers as to which tags may be messing up the display in Internet Explorer. The link to the page in question. http://www.paulvincentgandolfi.com/blog/?page_id=123 Thanks this is the code i'm having problems with: Code: <style type="text/css"> body { font: normal 10px Verdana, Arial, Helvetica, sans-serif; color:#666; margin : 0; padding : 0; } /* text */ h1 { font: bold 10px Verdana, Arial, Helvetica, sans-serif; line-height:30px; } /* div classes */ div.row { position:relative; left:10px; width:326px; height:20px; z-index:1; margin-bottom:8px; text-align:right; } div.cell_title, div.cell_content { position:absolute; top:0px; float:left; padding:0px 0px 0px 8px; border:1px solid #E4E4E4; text-align:left; line-height:17px; } div.cell_title { background-color: #E4E4E4; left:0px; width:100px; z-index:2; } div.cell_content { background-color:#FCFCFC; left:100px; width:224px; z-index:3; } /* form elements */ .input { font: normal 10px Verdana, Arial, Helvetica, sans-serif; color:#666; background-color: #FCFCFC; height:15px; width:213px; border:0; } .textarea { font: normal 10px Verdana, Arial, Helvetica, sans-serif; color:#666; background-color: #FCFCFC; height:100px; width:213px; border:0; overflow:auto; } </style> <h1>Contact</h1> <form action="?menu=contact" method="post" name="contact"> <div class="row"> <div class="cell_title"><label for="name">name:</label></div> <div class="cell_content"><input type="text" class="input" name="name" id="name"/></div> </div> <div class="row"> <div class="cell_title"><label for="email">email:</label></div> <div class="cell_content"><input type="text" class="input" name="email" id="email" /></div> </div> <div class="row"> <div class="cell_title"><label for="message">message:</label></div> <div class="cell_content"><textarea class="textarea" name="message" id="message"></textarea></div> </div> <div class="row"> <input type="image" src="includes/images/btn_add.gif" name="Submit" value="Submit"> </div> </form> My problem is that my "row" div's overlay if their content is larger. Because of that i cannot see the send button from my form (the textarea height is bigger that the height of the "row" div - i need the layer to expland according to the content, but i don't want it to overlay on what is after it!). I hope that you understood my problem and could help my with it. Thanks in advance! what i'm trying to accomplish is two boxes next to each other inside a div, which i can scroll horizontally to see the two boxes. if you copy the code below it works correctly, only because the width of the parent div is set. Code: <style type="text/css"> #container { overflow:scroll; width:100px; } #parent { overflow:hidden; width:400px; } .box1 { border:1px solid black; float: left; height: 101px; width: 101px; } </style> <div id='container'> <div id='parent'> <div class='box1'></div> <div class='box1'></div> </div> </div> if i change width:900px in the parent div to width:auto then the boxes go underneath one another. That's the problem, the parent div should auto adjust to the width of both boxes. i'd really appreciate solving this. i can't have a fixed width on the parent div it should auto adjust and both boxes should be next to each other. Hi all, I'm working on the site http://boolarongpress.com.au and have hit a problem. In IE7 if you click into either the title or author search fields in the left hand nav menu the cpu usage maxes out and IE7 hangs. There is no javascript attached to these inputs. The problem seems to be caused by a line in the css, overflow: auto; This is set for the content div so that it scrolls as if it were a frame. If I remove this line from the css the problem dissappears but of course the content div no longer scrolls. Has anyone got any ideas on how I can fix/work around this issue? Cheers, Peter How do I make the DIV overflow in the below codes? It works in IE but not firefox. <html > <head> <style type="text/css"> html, body { height : 100%; } </style> </head> <body> <table style="height : 100%; width : 100%"> <tr style="height : 64px; background-color : Blue;"> <td></td> </tr> <tr style="height : auto; background-color : red;"> <td> <!-- THIS IS THE PROBLEM --> <div style="height :auto; overflow-y : scroll"> <!-- THIS IS THE PROBLEM --> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> asd<br /> </div> </td> </tr> <tr style="height : 64px; background-color : Blue;"> <td></td> </tr> </table> </body> </html> hi, I have 3 DIV's, The first div is like a menu header DIV and the second DIV is the menu links and the third DIV has some information I want to click on the first DIV then show the second DIV like a menu problem is the third DIV moves down.. How can i let the second DIV overflow over the third DIV without it moving down? Thanks While working on my site, I am testing it in Mozilla Firefox 1.0pr and IE 6. In my code: body, td, iframe, table, div, tr { font-variant: small-caps; margin-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 12px; color: #ffffff; background-color: #666666; scrollbar-3dlight-color: #666666; scrollbar-arrow-color: #666666; scrollbar-base-color: #666666; scrollbar-darkshadow-color: #666666; scrollbar-face-color: #666666; scrollbar-highlight-color: #666666; scrollbar-shadow-color: #666666; } a:link { color: #ffffff; text-decoration: none; } a:visited { text-decoration: none; color: #ffffff; } a:hover { text-decoration: none; color: #ff0000; } a:active { text-decoration: none; color: #ffffff; } select, option, textarea, input { border: #ffffff 1px solid; font-size: 11px; font-variation: normal; font-family: Verdana; background-color: #666666; } I would add "overflow: auto;" right under 'body, td, iframe, table, div, tr {' so that in Mozilla the scrollbars would not show up. However, when I load it in IE, the windows do not scroll at all. Is there a quick-fix for this, or what can I do so it will work properly in both browsers? tinyurl(dotcom)/6dw6jp4 Hi everyone I am a newbie here, Please have a look at the above link. The second box which has the therapist images and their names do not appear correctly on IE8. On all other browsers it seems to work fine. Can any one please have a look at the page and let me know a solutions. Thanks a lot. How do I create a div with a horizontal overflow? I have a div box which is 150px high and 200px wide. I need it to fill up the height and then overflow to the right so I can scroll it horizontally. The div box contains thumbnail images. #navList { background-color: #FF0000; height: 10px; overflow: none; width: 600px; float: left; line-height: 0px; } #navList li { float: left; cursor: pointer; overflow: none; } in every other browser the next div after the list touches navList, which contains images that are 42px high. in ie6, there are an extra 2 pixels. at first I put height: 42px; overflow: none, to see what would happen - and nothing did. i set it to 10 for kicks to see if the overflow would do anything at all and it's not. very confused today. |