	
	$(document).ready(function() {
	//alert("yay");
		if (document.all && document.styleSheets && document.styleSheets[0] && document.styleSheets[0].addRule){
			//document.styleSheets[0].addRule('div', 'behavior: url(http://www.casadinvis.ro/httpdocs/romana/system/application/cdv/css/iepngfix.htc)');
			//document.styleSheets[0].addRule('span', 'behavior: url(http://www.casadinvis.ro/romana/system/application/cdv/css/iepngfix.htc)');
			document.styleSheets[0].addRule('*', 'behavior: url(http://www.casadinvis.ro/romana/system/application/cdv/css/iepngfix.htc)');
			//document.styleSheets[0].addRule('li', 'behavior: url(http://www.casadinvis.ro/httpdocs/romana/system/application/cdv/css/iepngfix.htc)');
			//document.styleSheets[0].addRule('div', 'behavior: url(http://www.casadinvis.ro/httpdocs/romana/system/application/cdv/css/iepngfix.htc)');
			//document.styleSheets[0].addRule('span', 'behavior: url(http://www.casadinvis.ro/httpdocs/romana/system/application/cdv/css/iepngfix.htc)');
			//document.styleSheets[0].addRule('li', 'behavior: url(http://www.casadinvis.ro/httpdocs/romana/system/application/cdv/css/iepngfix.htc)');
		}
	});
	
	function applyFix(event) {
		$("#preload").css("display", "none");
	}
	
	function printFunction() {
		
		newWin = window.open("", "", "width=500, height=300, scrollbars=yes, statusbar=no")
		newWin.document.writeln('<HTML><HEAD><title>Print Preview</title>')
		newWin.document.writeln('<base target="_self"></HEAD>')
		//Adding Body Tag
		newWin.document.writeln('<body MS_POSITIONING="GridLayout" bottomMargin="0"');
		newWin.document.writeln(' leftMargin="10" topMargin="0" rightMargin="0">');
		newWin.document.writeln('<form method="post">');
		//Creating two buttons Print and Close within a HTML table
		newWin.document.writeln('<TABLE width=100%><TR><TD></TD></TR><TR><TD align=right>');
		newWin.document.writeln('<INPUT ID="PRINT" type="button" value="Print" ');
		newWin.document.writeln('onclick="javascript:location.reload(true);window.print();">');
		newWin.document.writeln('<INPUT ID="CLOSE" type="button" value="Inchide" onclick="window.close();">');
		newWin.document.writeln('</TD></TR><TR><TD></TD></TR></TABLE>');
		newWin.document.writeln($("#content").html());
		//Ending Tag of </form>, </body> and </HTML>
		newWin.document.writeln('</form></body></HTML>'); 
		newWin.focus();
		return(false);
	}