function fadeOut(img)
{
	var timer;
	var dw = img.height / 25;
	var dh = img.width / 25;
	
	function doFadeOut()
	{
		img.height -= dh;
		img.width  -= dw;
		if (0 == img.height || 0 == img.width) {
			clearInterval(timer);
			timer = null;
			xajax_deleteImage(new String(img.id).substr(1));
		}
	}

	if (null == timer) {
		timer = setInterval(doFadeOut, 25);
	}				
}
