This is a discussion on "Div stretch to bottom in IE6" within the Web Page Design section. This forum, and the thread "Div stretch to bottom in IE6 are both part of the Design Your Website category.
|
|
|
|
|
![]() |
||
Div stretch to bottom in IE6
|
||
| Notices |
![]() |
|
|
LinkBack | Thread Tools |
|
#1
|
||||
|
||||
|
A div with styles;
However, the success is not the same in IE6. I've tried height: 100% with a top margin but get the same results. The post won't stretch unless I give it a height value in px or similar (which of course will become too short or too long in a different screen res). Any clues? Many thanks Alex
Last Blog Entry: The Google Misconception (Feb 3rd, 2008)
|
|
|
|
#2
|
||||
|
||||
|
Re: Div stretch to bottom in IE6
I've got the same issue with a site I am working on too. A visual of the problem can be seen at www.justudios.com/Taneya . Only a problem in IE6. If I can find a solution to this problem I will post back, if not and someone else can help us that'd be wonderful too. Thanks!
Last Blog Entry: Happy Holidays - A Non Offensive way to say Merry Christmas? WRONG! (Dec 11th, 2007)
|
|
#3
|
|||
|
|||
|
Re: Div stretch to bottom in IE6
Hmm... A lot of people seem to have this problem, huh? The solution is to use Faux Columns...
Last Blog Entry: Windows Vista vs. Mac Leopard (Nov 4th, 2007)
|
|
#4
|
|||
|
|||
|
Re: Div stretch to bottom in IE6
Try adding 100% height to the body.
will not work because it's 100% of nothing. But by adding the 100% to the body tag, it will probably work. Crossing finger. |
|
#5
|
|||
|
|||
|
Re: Div stretch to bottom in IE6
Last Blog Entry: ASP Programming Tips and Technique (Oct 26th, 2007)
|
|
#6
|
||||
|
||||
|
Re: Div stretch to bottom in IE6
I tried using the height: 100% option and works fine in IE6, but doesn't do anything for me in FF or IE7. As for Faux Columns, I get what that guy is saying but in my case it wouldn't do me any good because it can only be used in set layouts and my design is fluid. So I had to figure something else out... Then it hit me... Spacer images. Yes, I know spacer images aren't the best solution, but it is an easy fix. The spacer image can be 1px in width and be as long as you need it to be. This will make the column be the size you need it to be.
If your text is dynamic then this is where we have a problem. I'm still looking for a better solution but haven't found anything so far as easy to use, or as versatile as a spacer image. Faux columns aren't a bad idea I guess, but they do limit you to a specific design type.
Last Blog Entry: Happy Holidays - A Non Offensive way to say Merry Christmas? WRONG! (Dec 11th, 2007)
Last edited by JustinStudios; Nov 27th, 2007 at 01:01. Reason: Numberd Browser Wrong |
|
#7
|
|||
|
|||
|
Re: Div stretch to bottom in IE6
That's weired! My IE7 and FF behave nicely!
Last Blog Entry: ASP Programming Tips and Technique (Oct 26th, 2007)
|
|
#8
|
||||
|
||||
|
Re: Div stretch to bottom in IE6
Ok, I found out why mine doesn't work in IE7/FF I don't use positioning. My sites a fluid layout, and therefore its all setup based on divs and floats.
When I used positioning this fixed, but of course I can't use it. I also found that if you have more text then 100% screen size Example - you have to scroll down to read, the 100% height fix doesn't work anymore. One column expands to fit the content, whilst the other stays at the 100% height line.
Last Blog Entry: Happy Holidays - A Non Offensive way to say Merry Christmas? WRONG! (Dec 11th, 2007)
|
|
#9
|
|||
|
|||
|
Re: Div stretch to bottom in IE6
Yes, css becomes tricky when you use fluid layouts...
I haven't some across any fixes for "filling the column", but I think padding is better than a spacer!
Last Blog Entry: Windows Vista vs. Mac Leopard (Nov 4th, 2007)
|
|
#10
|
||||
|
||||
|
Re: Div stretch to bottom in IE6
The reason you can't use padding is because your content is different lengths on each page. So you'd have to have a different style sheet for each page, or, dare I say, inline styles (There goes the validation).
With a spacer your not adding any code and not doing anything wrong by validation rules. Now SEO you might take a hit, but I doubt it could be that bad.
Last Blog Entry: Happy Holidays - A Non Offensive way to say Merry Christmas? WRONG! (Dec 11th, 2007)
|
|
#11
|
|||
|
|||
|
Re: Div stretch to bottom in IE6
Oh, ok. I see what you're saying now (my brain wasn't working...)
Last Blog Entry: Windows Vista vs. Mac Leopard (Nov 4th, 2007)
|
|
#12
|
|||
|
|||
|
Re: Div stretch to bottom in IE6
If you want equal-height columns, the obvious solution is "display: table-cell".
|
|
#13
|
||||
|
||||
|
Re: Div stretch to bottom in IE6
Lchad, you're a legend
Last Blog Entry: The Google Misconception (Feb 3rd, 2008)
|
|
#14
|
|||
|
|||
|
Re: Div stretch to bottom in IE6
I learned something new too! Glad it worked!
|
|
#15
|
||||
|
||||
|
Re: Div stretch to bottom in IE6
Hrmm, Mike can you explain the table-cell more. I'm doing google searches atm but haven't come across anything too creative yet. I've also been toying around with the coding to fix this. My problem is I'm using a fluid layout, positioning is a no go for me. Well, I dont use positioning on hardly any of my layouts, even static, but that's because I was taught to steer clear of them unless you got into a situation where it was absolutely the last resort.
Last Blog Entry: Happy Holidays - A Non Offensive way to say Merry Christmas? WRONG! (Dec 11th, 2007)
|
|
#16
|
|||
|
|||
|
Re: Div stretch to bottom in IE6
Quote:
|
|
#17
|
|||
|
|||
|
Re: Div stretch to bottom in IE6
"display: table-cell" is not positioning. Positioning is setting "position: relative/absolute/fixed".
It simply works as a table would. Why spend all this effort to replicate table designs with floats, when you can use a <div> as a <table>? (And you can still use floats inside the "table".) The downside is that IE doesn't support it, but this can be fixed with a javascript hack for IE (see the other thread). |
![]() |
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| [SOLVED] How to get my footer to stretch | Gav | Web Page Design | 3 | Dec 16th, 2007 14:15 |
| [SOLVED] wont stretch | lostyboy | Web Page Design | 2 | Oct 18th, 2007 14:25 |
| stretch div with no content | nate2099 | Web Page Design | 4 | Jul 13th, 2007 13:36 |
| Site Stretch with Content? | CodyFunderburg | Web Page Design | 4 | Nov 20th, 2006 14:58 |