Engine = {
	detect: function() {
		var UA = navigator.userAgent;
		this.isKHTML = /Konqueror|Safari|KHTML/.test(UA);
		this.isGecko = (/Gecko/.test(UA) && !this.isKHTML);
		this.isOpera = /Opera/.test(UA);
		this.isMSIE6 = (/MSIE 6/.test(UA) && !(/MSIE 7/.test(UA)) && !this.isOpera);
		this.isMSIE7 = (/MSIE 7/.test(UA) && !this.isOpera);
	}
};

ieImgReplace = function() {
	Engine.detect();
	// poor IE6 gets no shadows, ha!
	if (Engine.isMSIE6) {
		$$('img').each(function(s){
			s.src = s.src.replace(/png/, 'gif');
		});
	}
};

setSize = function() {
	if (!Engine.isMSIE6 && !Engine.isMSIE7) {
		$$('img').each(function(s){
			s.setStyle({width: '100%', height: '100%'});
		});			
	}
};

