
	function FP_preloadImgs() {//v1.0
	 var d=document,a=arguments; if(!d.FP_imgs) d.FP_imgs=new Array();
	 for(var i=0; i<a.length; i++) { d.FP_imgs[i]=new Image; d.FP_imgs[i].src=a[i]; }
	}
	
	function FP_swapImg() {//v1.0
	 var doc=document,args=arguments,elm,n; doc.$imgSwaps=new Array(); for(n=2; n<args.length;
	 n+=2) { elm=FP_getObjectByID(args[n]); if(elm) { doc.$imgSwaps[doc.$imgSwaps.length]=elm;
	 elm.$src=elm.src; elm.src=args[n+1]; } }
	}
	
	function FP_getObjectByID(id,o) {//v1.0
	 var c,el,els,f,m,n; if(!o)o=document; if(o.getElementById) el=o.getElementById(id);
	 else if(o.layers) c=o.layers; else if(o.all) el=o.all[id]; if(el) return el;
	 if(o.id==id || o.name==id) return o; if(o.childNodes) c=o.childNodes; if(c)
	 for(n=0; n<c.length; n++) { el=FP_getObjectByID(id,c[n]); if(el) return el; }
	 f=o.forms; if(f) for(n=0; n<f.length; n++) { els=f[n].elements;
	 for(m=0; m<els.length; m++){ el=FP_getObjectByID(id,els[n]); if(el) return el; } }
	 return null;
	}

	function ShowGame(GameName)
	{
	   
	    elem = '<p align="center" valign="top"><object classid="clsid:D27CDB6E-AE6D-11CF-96B8-444553540000" id="obj0" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0" border="0" width="800" height="600">';
		elem += '<param name="movie" value="http://www.kufur-kassem.com/cms/Games/'+GameName+'.swf">';
		elem += '<param name="quality" value="High">';
	    elem += '	<embed src="http://www.kufur-kassem.com/cms/Games/'+GameName+'.swf" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" name="obj0" width="800" height="600"></object></p>';

        

	           popup = window.open('','popup','resizable=yes,scrollbars=yes,toolbar=no,menubar=no,width=800,height=600'); 
	       popup.document.open(); 
	       popup.document.write("<html dir=\"rtl\"><head></head><body style=\"text-align:right\">"); 
	       popup.document.write(elem);
	       popup.document.write("</body></html>"); 
	       popup.document.close(); 
	
	}
	function getIEVersionNumber() 
    {
	    var ua = navigator.userAgent;
	    var MSIEOffset = ua.indexOf("MSIE ");
	    
	    if (MSIEOffset == -1) {
	        return 0;
	    } else {
	        return parseFloat(ua.substring(MSIEOffset + 5, ua.indexOf(";", MSIEOffset)));
	    }
    }

	function ShowExplorerUpdate()
	{
		var isIELessThan7 =false;
		var broNum = getIEVersionNumber();
		
		if(broNum < 7 && broNum >0)
		{
		   isIELessThan7 =true;
		}
		
		if (isIELessThan7) 
		{
		    var elem ='<table border="1" width="100%" id="table1" dir="rtl">';
				elem +='<tr>';
				elem +='		<td><span lang="ar-sa">&#1604;&#1605;&#1588;&#1575;&#1607;&#1583;&#1577; &#1575;&#1604;&#1605;&#1608;&#1602;&#1593; &#1576;&#1589;&#1608;&#1585;&#1607; &#1575;&#1601;&#1590;&#1604; &#1575;&#1604;&#1585;&#1580;&#1575;&#1569; &#1578;&#1581;&#1583;&#1610;&#1579; &#1575;&#1589;&#1583;&#1575;&#1585; ';
				elem +='		&#1575;&#1604;&#1593;&#1575;&#1585;&#1590; </span>&nbsp;explorer</td>';
				elem +='		<td width="48">';
				elem +='		<a href="http://www.google.com/chrome/index.html?hl=ar&brand=CHNG&utm_source=ar-hpp&utm_medium=hpp&utm_campaign=ar">';
				elem +='	    	<img border="0" src="http://www.kufur-kassem.com/cms/templates/alqaria/images/Google_Chrom_Icon.gif" width="48" height="48"></a></td>';
				elem +='		<td width="48">';
				elem +='		<a href="http://www.microsoft.com/Downloads/details.aspx?familyid=9AE91EBE-3385-447C-8A30-081805B2F90B&displaylang=en">';
				elem +='		    <img border="0" src="http://www.kufur-kassem.com/cms/templates/alqaria/images/ie7_Icon.jpg" width="48" height="48"></a></td>';
				elem +='		<td width="48"><a href="http://www.mozilla.com/en-US/firefox/all.html">';
				elem +='		    <img border="0" src="http://www.kufur-kassem.com/cms/templates/alqaria/images/FireFox_Icon.jpg" width="48" height="48"></a></td>';
				elem +='	</tr>';
				elem +='</table>';
				
				document.write(elem);
	
		}
	}

