473,832 Members | 2,090 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Relative box positioning: IE vs FF problem..

Hi

Sorry no screen shots or links...I want to achieve the following visual
effect:

I want three boxes to appear on screen, all within a parent box (so 4
in total).

Concerning the three inner boxes, I want them to appear in a two column
format. One box in the left hand column that will contain an image and
the two other boxes stacked one above the other in the right hand
column that will contain text.

Using relative positioning, I can achieve what I want for the three
internal boxes and this works in Internet Explorer (IE) and in FireFox
(FF).

However, when I add the parent box it "correctly" surrounds the
daughter boxes in IE, but appears as a thin strip in FF (i.e. the
daughter boxes hang out of the bottom of this box).

I can't use absolute positioning because I don't know how much text
these will contain, or how big the image will be.

The HTML text is simply three <div/elements embedded within a parent
<div/>.

Any help would be most appreciated in this.

Thanks

Griff

Aug 17 '06
13 2472
Rik wrote:
Andy Dingley wrote:
>Griff wrote:
>>I want three boxes to appear on screen, all within a parent box (so 4
in total).
Go and read brainjar.com and their article on "css positioning"

(Floats are _meant_ to hang out of the bottom of things, unless you
tell them not to. IE gets things wrong again).

Or check http://www.quirksmode.org/css/clearing.html for a nice compact
decription/solution.
I think the quirksmode suggestions is suspect.

There could be no objection to the "old" method of clearing the floats
before closing the containing div but the suggestion to use the overflow
property hack is not a good one in my opinion.

Firefox, for one, treats overflow:hidden (and overflow:visibl e) as would
be expected; without the containing div having a set or implied height,
its contents cannot be viewed.

As for overflow:auto, who's to know if this will result in some browser
drawing scroll bars.

http://www.w3.org/TR/REC-CSS2/visufx...opdef-overflow

Louise
Aug 17 '06 #11
Rik
boclair wrote:
Rik wrote:
>Andy Dingley wrote:
>>Griff wrote:

I want three boxes to appear on screen, all within a parent box
(so 4 in total).
Go and read brainjar.com and their article on "css positioning"

(Floats are _meant_ to hang out of the bottom of things, unless you
tell them not to. IE gets things wrong again).

Or check http://www.quirksmode.org/css/clearing.html for a nice
compact decription/solution.

I think the quirksmode suggestions is suspect.
Not ideal by any means, but workable.
There could be no objection to the "old" method of clearing the floats
before closing the containing div but the suggestion to use the
overflow property hack is not a good one in my opinion.

Firefox, for one, treats overflow:hidden (and overflow:visibl e) as
would be expected; without the containing div having a set or implied
height, its contents cannot be viewed.

As for overflow:auto, who's to know if this will result in some
browser drawing scroll bars.
Well, you as the deisgner usually know. It's a method with several prerequisites
(?). I'll only use it on a container with set by either the container itself or
it's parents, or one set dimension which I know is not going to overflow in that
dimension due to content-dimensions, which I'm in control of.

On a completely unpredictable system (CMS's for third parties etc.), it isn't a
true solution, that's right. If only you yourself will be working on it it will
save you a lot of headache/HTML-clutter.

Grtz,
--
Rik Wasmus
Aug 17 '06 #12
On 2006-08-17, Rik wrote:
boclair wrote:
>>
As for overflow:auto, who's to know if this will result in some
browser drawing scroll bars.

Well, you as the deisgner usually know.
You do not know; you *cannot* know.

You don't know the size of my browser window, or my font size. You
are making an assumption that is responsible for vast numbers of
badly rendered pages on the WWW.
It's a method with several prerequisites (?). I'll only use it on a
container with set by either the container itself or it's parents,
or one set dimension which I know is not going to overflow in that
dimension due to content-dimensions, which I'm in control of.

--
Chris F.A. Johnson <http://cfaj.freeshell. org>
=============== =============== =============== =============== =======
Author:
Shell Scripting Recipes: A Problem-Solution Approach (2005, Apress)
Aug 17 '06 #13
boclair wrote:
I think the quirksmode suggestions is suspect.
That's because of your calm and generous nature.

I think it's a fecking evil bogosity and would have nothing at all to
do with the perverse idea.

Aug 17 '06 #14

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
11022
by: Ken Kast | last post by:
Here's my situation. I have a statically positioned table that has an image in a cell. I also have some layers, defined by absolute-positioned DIVs for some animation. Everything works until I scroll/resize. Then the image "moves" on the screen but the animation doesn't. The net effect is that their relative positioning changes. I'd like to have it be that they would stay in the same relative position. I want to keep the image as an...
2
7755
by: Stephen Weatherly | last post by:
Could anyone please help me with a problem I am having with my table widths??? If I have 2 images within a td tag, but using CSS relative positioning I position one over the top of the second (I am placing a transparent gif over the top of a normal gif) then the width of my table is large enough to accommodate both images side by side My browsers (both IE ad Firefox) do not appear take into account the relative positioning of my...
2
12043
by: Catherine Lynn Wood | last post by:
I need to know how to overlap DIV content within 'relative' associated rendering. I am building div layers in the middle of a page and when I set positioning to absolute in the CSS, it references back to 0,0 on the entire page. If I set it to relative, the div layers will not overlap as needed. I prefer to avoid javascripting an 'innerHTML' re-write of a single div and would instead like to build two layers that can reside at the same...
1
5371
by: Wilhelm Kutting | last post by:
Hi i like to make a complex layout with css. All the content is inside a container div. I like to get the following sequence without the css-layout: logo title mainnav content i can only get the results when i use negative positioning.
3
19784
by: Markus Ernst | last post by:
Hello Reading the follwing document: http://www.w3.org/TR/WD-positioning-970131#In-flow it seems very clear that position:relative should be relative to the parent element. So in the following test case element1 and element2 should be placed side by side inside a centered white container element: http://www.markusernst.ch/test.htm
1
1813
by: Fred Nelson | last post by:
Hi: I'm working on one of my first web applications in asp.net 2.0 and I'm having a problem with absolute versus relative positioning of controls that I place on pages that use master pages with Content Place Holders. The controls placed in a content area with absolute or relative positioning can easily "drift" beyond my Content Place Holder. I'm trying to put a "footer" on every page of the site and this is
2
3170
by: nonsensitor | last post by:
I'm just learning xhtml & css, primarily from westciv's online tutorials and css guide. I've run into a couple of problems with a page I'm developing that I can't figure out. The first problem is that I would like to display some text on top of an image within the header. I've tried using absolute positioning to specify where the phone number should appear in relation to the parent div (#header). However the text appears to be positioned in...
3
8987
by: mikewse | last post by:
I have a strange problem where it seems IE is doing the correct layout but Firefox and Safari isn't. I think I'm probably wrong, and there is something in the standards that say behaviour should be like Firefox does, but could someone tell me what is right? In the below code I have element trees with three DIVs; the outer DIV establishes a positioning context and the "middle" DIV uses absolute positioning to put its top left corner in the...
7
9307
by: Cruelemort | last post by:
All, I have a div in my page that has a set width of 1000px, height of 200px, inside this i declare two more div's, both relatively positioned and floated left, the first is placed to the top left of the box and is a 30px square, the other one is set to 970px and is naturally positioned next to the square and so fills all the way to the right hand edge of the box. Now i need the second (wider) box to overlap the square and so start
0
2039
by: slaterino | last post by:
Hi, I am in the process of creating a web site at the following address: http://www.cca-ltd.co.uk/New/en/index.html At the moment when you hover over the navigation links a list appears on the training and support tabs. This works fine in Firefox but in IE (I have v7.0) the list jumps to the right instead of dropping straight down from the menu. If i change the positioning on the #navstrip li ul element to relative this fixes the...
0
10780
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10498
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10540
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10212
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9319
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5623
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5789
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4421
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3970
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.