Results 1 to 8 of 8
Not working in IE Forum: HTML ForumReplies: 2
Setting Div widths Forum: CSS ForumReplies: 0
what do you think of a new project im working on? Forum: Show it off!Replies: 3
Why isn't this working? Forum: HTML ForumReplies: 5
It's 3:00 AM here and I'm working the ..... Forum: General DiscussionReplies: 47
11-06-2003, 10:46 AM #1
CSS Percentage widths not working
I'm trying to move away from tables and into CSS for my site layout. Biggest snag so far is that I've got everything working on one machine running IE 6, but when I move to another machine running IE5, the percentage widths are no longer recognized.
I'm using div tags and controlling layout with, for example "margin-right:25%," for example.
Here's the code:
I can't imagine that IE5 doesn't support this. Any ideas about what the problem might be would be greatly appreciated.
11-07-2003, 04:12 PM #2
When you say they are not recognised, do you mean they are completely ignored or are slightly different (enough to break them, for example)?
The reason I ask is that IE 5* has a broken box-model compared to the w3 spec. They fixed (ish) this in IE6.
If thats the case, try the Box-Model Hack http://tantek.com/CSS/Examples/boxmodelhack.html by Tantek Celik.
11-11-2003, 09:35 AM #3
When I view the page in IE5, all page elements (divs) are aligned left.
11-11-2003, 10:07 AM #4
use text-align to align them where you wish
11-11-2003, 10:12 AM #5
Forgive my lack of clarity. What I mean by aligned left is that every element the page is clumped together along the left edge, stacked one atop the other based on the z-index. The margin values are being ignored.
11-11-2003, 10:13 AM #6
could you post a link to an example? its hard to visualise.
11-17-2003, 04:14 PM #7
Thanks for your replies. I fixed the problem by changing from margin-left, to simply "left" for the percentage width. My lingering question is, what's the functional difference?
11-17-2003, 05:49 PM #8
Not one I have used much myself, heres the standard - http://css.somepeople.net/css2ref/Standard/visuren.html#propdef-left
I think its main difference is the differing way it behaves depending on whether its containing element is absolute or relatively positioned.