473,587 Members | 2,443 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Floated image in a relative position div

Is this a known problem with IE6?

I have a provisional two column layout, the left menu column is positioned
absolute. The contents column is positioned relative.

The contents column has an image floated right. The placement is there in
IE6 but not the image.

It does not matter whether the DTD is strict or transitional

An incomplete test page is at http://www.australisolives.com/new1/

I notice that if I drag the window width to about 550 pixel (on a 800 res),
part of the image can be seen in the margin between the right column and the
left column. The image seems to be being layered under the right column.
z-index "is" declared on the right column but it doesn't seem to matter, in
relation to the jpg, whether it is declared or not, or a higher z-index is
declared on the floated image.

I have read http://www.w3.org/TR/REC-CSS2/visuren.html#q24 and subsequent
sections but cannot seem to find anything relative

Any assistance appreciated.

Louise
Jul 20 '05 #1
4 8270
boclair wrote:
Is this a known problem with IE6?

I have a provisional two column layout, the left menu column is positioned
absolute. The contents column is positioned relative.

The contents column has an image floated right. The placement is there in
IE6 but not the image.


Sounds like the IE6 Guillotine bug - although the issue is well known
the exact fix isn't.

I recently had a similar problem but I'm not sure how to adapt my
solution to your case as you have an absolute left position column.

The problem - from what I have seen - apparently has to do with IE6
messing up positioning a floated image that has a hyperlink wrapped
around it and that apparently the link background extends outside of its
container and thus causes a number of weird effects - depending on the
rest of the layout (not a very obvious thing for MS to have tested is
it????? - sarcasm intended ;-)

The problem is that this bug is no joke and can cause a lot of grief.

Solutions I have heard of involve wrapping another div around the float
img and possibly setting the width to 100% of the div - all in an effort
to keep this floated element under control. Neither worked for me and I
ended up making the element opposite the float a float as well and this
seems to work (although there is a small boundary when the window is
between 500-520 or so pixels wide that both floats dissappear).

Some have also mentioned doing a img {position: relative} on the floated
image as a work around but once again I saw no change -

If this isn't the Guillotine bug then count yourself lucky.

If it is, you'll probably unfortunately find it easier to switch layouts
before you'll ever solve it (at least that has been my experience).

--Nikolaos

Jul 20 '05 #2
Nikolaos Giannopoulos wrote:
boclair wrote:
The contents column has an image floated right. The placement is there in
IE6 but not the image.


Sounds like the IE6 Guillotine bug - although the issue is well known
the exact fix isn't.
[...]
The problem - from what I have seen - apparently has to do with IE6
messing up positioning a floated image that has a hyperlink wrapped
around it and that apparently the link background extends outside of its


I've hit that bug only once and all I could do was to add "background :
transparent" for the offending element[1]. In that case, it was easiest
to just hide the issue. The element is still rendered incorrectly but
because it's rendered as transparent, it doesn't matter.

[1] If Guillotine bug is indeed related to backgrounds only it should be
"easy" to locate the incorrectly rendered element by changing all
backgrounds to transparent and then restoring real backgrounds one by
one until the bug shows up again.

--
Mikko

Jul 20 '05 #3
Mikko Rantalainen wrote:
Nikolaos Giannopoulos wrote:
The problem - from what I have seen - apparently has to do with IE6
messing up positioning a floated image that has a hyperlink wrapped
around it and that apparently the link background extends outside of its
I've hit that bug only once and all I could do was to add "background :
transparent" for the offending element[1].


Interesting. This hasn't helped in any of my cases unfortunately.

In that case, it was easiest
to just hide the issue. The element is still rendered incorrectly but
because it's rendered as transparent, it doesn't matter.
If this worked it would be a great thing - and super easy to implement
but in most cases that I have come accross this hasn't made a
difference. In addition I'm not sure that its so much that the
background is opaque that causes the problem or that the rendering
engine simply miscalculates things by making the appropriate space for
an element but through a bug incorrectly computing the background to be
larger than it really is and thus not being able to place the element.

I think its the latter in most cases that I have come accross as the
element that is being floated is ussually the thing that dissappears.
Wrapping another element inside a div with the floated element has been
observed to take out both elements.

[1] If Guillotine bug is indeed related to backgrounds only it should be
"easy" to locate the incorrectly rendered element by changing all
backgrounds to transparent and then restoring real backgrounds one by
one until the bug shows up again.


I wish. Like I said I think its more of a miscalculation when placing
the element than the opaqueness of the background of the element - this
is why a weird rule like the following sometimes fixes things.

#show {float: left; position: relative}

or why for quite some time now I have picked up from this newsgroup that
its wise to have the following in your style sheet:

body * {position: relative}

The above I imagine helps but the problem is that there are many
different combinations of things that can cause this bug to appear and
thus the inability to focus on a single solution.

What amazes me is that this bug wasn't picked up before IE was released
- Did I just say that ;-)

Finally, I have observed IE 5 and IE 6 win to behave the same way on
this bug!!!! i.e. when the bug appears in one browser it will appear in
the other - when the page is adjusted the new behaviour fixed or not
will be the same in both browsers. So this is not just an IE 6 bug IMO.

--Nikolaos
Jul 20 '05 #4
Nikolaos Giannopoulos wrote:
I think its the latter in most cases that I have come accross as the
element that is being floated is ussually the thing that dissappears.
Wrapping another element inside a div with the floated element has been
observed to take out both elements.


Have I misunderstood you here? Or did you misunderstand my solution?

Given

<a href="foo.html" ><img src="foo.png"></a>
with
img {float: left } /* or */
a {float: left }

we see a bug, what you call the guillotine bug. Change it to

<div>
<a href="foo.html" ><img src="foo.png"></a>
</div>
with
div {float: left }

That is, take the float off the inline element. Put it on the block
element. But that is what you tried, right?

--
Brian
follow the directions in my address to email me

Jul 20 '05 #5

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

Similar topics

2
5689
by: sylvian stone | last post by:
Hi, I'm trying to do something that has always been easy with tables - namely use a three column layout, and above the main layout, show three images - one on the absolute left, one on the absolute right, and one in the middle. The one in the middle needs to be centered, as various browsers display slightly differently. However, using the CSS and code below, either the first image is not shown (IE) or the right image is shown below...
4
14709
by: Jay | last post by:
Hi, How can I capture mouse position on Image? I found number of script capturing mouse position of the page. But I could not find anything based on image. What I want to find out is X Y coordinates of mouse position. based on left of the top of my image is 0 0 (X Y coordinates) otherwise, I need to find out position of my image so I can calculate.
4
2881
by: sweep | last post by:
Hi there, I have a problem with some CSS I'm writing and I was looking for a little help. I have a nav bar at the top and left side of my page in CSS which work fine. The remaining space has a div which I'm using for body text. Floated to the right of this are two image boxes and a broken out quotation from the page (this box is wider than the images). The layout is working, except that the text in the main section doesn't seem to wrap...
9
3710
by: edski | last post by:
Using a technique I found here: http://www.vertexwerks.com/tests/sidebox/ I created these "dialogue" boxes: http://www.ebph.org/test.htm In IE6, the text does not wrap correctly around the image, which is floated right. Any ideas / suggestions?
2
4244
by: Dale | last post by:
This seems like it should be simple and I am pretty sure I've done similar things a hundred times before but I sure can't seem to get it right this time. I have a GridView with a column of text boxes. If I want to position an image over the GridView just below, for instance, the textbox in row 4 of the GridView. I don't care that it covers the other textboxes. I am successfully obtaining the textbox and the image objects in client-side...
6
10522
by: Seth Illgard | last post by:
Hi, Im writting a custom CMS and everything looks great, except when I see the results in IE. What im trying to do is: *Have an image in a layer (or relative positioned, or just margined). The exact image's coordinates depends in the window size (Fluid design) *The image should display correctly in front(above) another image (header image)
1
3134
by: rsteph | last post by:
I've got some product information pages, with images and text, all setup within a table. I'm trying to add a small image in the upper right hand corner of the content div (where all the important information is). I've got the product name at the top, left aligned and typically as a two lined header, and I'd like to add a small logo to the right of that, either right beside it, or in the far right corner. could anyone help me with how to set...
1
2204
by: yawnmoth | last post by:
I'd like to center two floated divs but am unsure of how to do so. Here's my code: http://www.frostjedi.com/terra/scripts/demo/div-float-center.html It seems like setting the width of the outer div to 200px might work but I don't want to do that because you're not always going to know the width in advance...
1
3116
by: rirby2 | last post by:
Hi everyone, I'm currently having a rendering problem in IE7 (haven't even tried the lower IEs yet), vs. what I see in FF2. The simplified site can be found at solerasd.com . (There are more image elements that belong in the list but I've only posted 2 since it replicates the problem and minimizes the code to read. In FF, you should see a logo with two images (currently not HREF's) of the same size below it, and a copyright statement below...
0
8219
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
8349
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...
0
8221
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
5395
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
3845
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
3882
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2364
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
1
1455
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
1192
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.