﻿//Use this function to add things to do at window.onload
function addLoadEvent(func) 
{
	var oldonload = window.onload;
	if (typeof window.onload != 'function') 
	{
		window.onload = func;
	} 
	else 
	{
		window.onload = function() {
			if (oldonload) 
			{
				oldonload();
			}
			func();
		}
	}
}

//This function allows png files with transparency to work in IE6
//refer to http://24ways.org/2007/supersleight-transparent-png-in-ie6
function fixPng(img) 
{
	var src = img.src;
	img.style.width = img.width + "px";
	img.style.height = img.height + "px";
	img.style.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" + src + "', sizingMethod='scale')";
	img.src = "../images/x.gif";
}

