function applyTransparencyHack(element) { //create the background container var backContainer = $new('DIV'); //apply the same location, dimension and background properties of the element backContainer.style.width = element.style.width; backContainer.style.height = element.style.height; backContainer.style.background = element.style.background; backContainer.style.opacity = element.style.opacity; backContainer.style.position = 'absolute'; backContainer.style.top = element.style.top; backContainer.style.left = element.style.left; //remove background definitions from the element element.style.background = ''; element.style.opacity = 1; //now append the background container before the element element.appendBefore(backContainer); }