Fairly
Replacing PNG images manually is a tedious task if you??™ve got more than a couple on
your site. If you regularly work with PNG transparency, it??™s worth investigating
JavaScript alternatives (such as the one shown at www.bjorkoy.com/past/2007/4/8/
the_easiest_way_to_png/) for automating the method shown in this section.
DEALING WITH BROWSER QUIRKS
365
9
common (but also fairly random as to whether it occurs), it typically affects layouts that
use floats and clearing divs, and it can cause elements to partially disappear below a given
point, or for content to flicker on and off as a page is scrolled.
The problem occurs due to a proprietary Internet Explorer concept called ???layout,??? which
refers to how elements render their content and interact with other elements. Some elements
have layout by default, others don??™t, and some CSS properties (irreversibly) trigger
it. Any property that gains layout in some way has Microsoft??™s proprietary hasLayout property
set to true. If an element doesn??™t have layout, the property is set to false.
Unfortunately, there??™s no way to directly set hasLayout for any element, even in an IEspecific
style sheet, and yet hasLayout is the cause of many layout problems in Internet
Explorer.
The hasLayout-trigger.html document within the hasLayout folder from the chapter 9
folder of the download files always exhibits the peekaboo bug. The page??™s structure is
extremely simple: a wrapper has within it three divs; the first is floated right and given a
50% width, the second has no style applied, and the third is a clearing div.
Pages:
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471