|
Server : Apache/2.4.62 System : FreeBSD fbsdweb2.web.rcn.net 14.1-RELEASE FreeBSD 14.1-RELEASE releng/14.1-n267679-10e31f0946d8 GENERIC amd64 User : www ( 80) PHP Version : 8.3.8 Disable Function : NONE Directory : /domains/highlandlabs/cqi-bin/ALFA_DATA/alfasymlink/root/domains/insite/ |
Upload File : |
/*
Author: Darren Northcott
Date: Jan 17 2008
This script will pull all of the images out of your file and apply the IE fix to .png images to handle transparency
---[USAGE: this script MUST be placed at the bottom of your HTML file (after the </body> before the </html> otherwise it will not work!
also, place between a <!--[if IE}> and <![endif]--> tag]---
*/
var imgs = document.getElementsByTagName('img');
for(var i=0;i<document.images.length;i++)
{
var imgName = imgs[i].src.toUpperCase()
if (imgName.substring(imgName.length-3, imgName.length) == "PNG")
{
imgs[i].style.filter ='progid:DXImageTransform.Microsoft.Alpha(opacity=0);';
var tag = imgs[i].outerHTML;
imgs[i].outerHTML = '<span style="'+imgs[i].style.cssText+';width:'+imgs[i].width+';height:'+imgs[i].height+';display:inline-block;filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src=\''+imgs[i].src+'\');">'+tag+'</span>';
}
}