This is a discussion on "Transparent Background Issues (especially in IE6)" within the Web Page Design section. This forum, and the thread "Transparent Background Issues (especially in IE6) are both part of the Design Your Website category.
|
|
|
|
|
![]() |
||
Transparent Background Issues (especially in IE6)
|
||
| Notices |
![]() |
|
|
LinkBack | Thread Tools |
|
#1
|
|||
|
|||
|
Transparent Background Issues (especially in IE6)
Hi,
I'm building a website for a friend of mine. Basically, there's a section with a transparent grey PNG used for the background (by setting the background image URL in the default CSS sheet). This is all fine until I test it on IE6. I got through the initial prolem of IE6's hideous lack of PNG transparency by using this code in the IE6 CSS sheet: * html img, * html div, * html .png{ position:relative; behavior: expression((this.runtimeStyle.behavior="none")&&(t his.pngSet?this.pngSet=true this.runtimeStyle.filter = "progid this.src = "transparent.gif") this.runtimeStyle.filter = "progid this.runtimeStyle.backgroundImage = "none")),this.pngSet=true) ); } Then I put the background in the HTML page with this code: <!--[if IE 6]> <div id="transblock" style="background-image: url(images/blackbgrnd.png);"></div> <![endif]--> Only problem is that now the background seems to double up and place itself above the text and links of the rest of the page., effectivly leaving anything in that section untouchable by the user. I've zipped the site and added it here (http://www.webdesignerforum.co.uk/in...pe=post&id=709) if anyone could have a look. If anyone's got any thoughts about this, I'd be incredibly greatful to hear them. Cheers Al |
|
|
|
#2
|
||||
|
||||
|
Re: Transparent Background Issues (especially in IE6)
Scrap the expression code and use IE PNG Fix instead.
Last Blog Entry: The Google Misconception (Feb 3rd, 2008)
|
![]() |
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| repeating background issues. | Therealmatt | Starting Out | 4 | Sep 20th, 2007 22:54 |
| Help with transparent background | jenslennartsson | Web Page Design | 2 | Jul 4th, 2006 03:53 |
| how to create a .png semi-transparent image for background | laurablue3 | Web Page Design | 2 | Nov 20th, 2005 12:06 |
| transparent background | krazykrisi | Web Page Design | 1 | Aug 25th, 2005 08:51 |
| How to get a transparent background in Fireworks | blh9901 | Graphics and 3D | 1 | Aug 3rd, 2005 01:16 |