/* SWFObject v1.5.1: Flash Player detection and embed - http://blog.deconcept.com/swfobject/
 * SWFObject is (c) 2007 Geoff Stearns and is released under the MIT License:
 * http://www.opensource.org/licenses/mit-license.php */
if(typeof deconcept=="undefined"){var deconcept={}}if(typeof deconcept.util=="undefined"){deconcept.util={}}if(typeof deconcept.SWFObjectUtil=="undefined"){deconcept.SWFObjectUtil={}}deconcept.SWFObject=function(f,d,m,g,j,l,n,i,a,e){if(!document.getElementById){return}this.DETECT_KEY=e?e:"detectflash";this.skipDetect=deconcept.util.getRequestParameter(this.DETECT_KEY);this.params={};this.variables={};this.attributes=[];if(f){this.setAttribute("swf",f)}if(d){this.setAttribute("id",d)}if(m){this.setAttribute("width",m)}if(g){this.setAttribute("height",g)}if(j){this.setAttribute("version",new deconcept.PlayerVersion(j.toString().split(".")))}this.installedVer=deconcept.SWFObjectUtil.getPlayerVersion();if(!window.opera&&document.all&&this.installedVer.major>7){if(!deconcept.unloadSet){deconcept.SWFObjectUtil.prepUnload=function(){__flash_unloadHandler=function(){};__flash_savedUnloadHandler=function(){};window.attachEvent("onunload",deconcept.SWFObjectUtil.cleanupSWFs)};window.attachEvent("onbeforeunload",deconcept.SWFObjectUtil.prepUnload);deconcept.unloadSet=true}}if(l){this.addParam("bgcolor",l)}var b=n?n:"high";this.addParam("quality",b);this.setAttribute("useExpressInstall",false);this.setAttribute("doExpressInstall",false);var k=(i)?i:window.location;this.setAttribute("xiRedirectUrl",k);this.setAttribute("redirectUrl","");if(a){this.setAttribute("redirectUrl",a)}};deconcept.SWFObject.prototype={useExpressInstall:function(a){this.xiSWFPath=!a?"expressinstall.swf":a;this.setAttribute("useExpressInstall",true)},setAttribute:function(a,b){this.attributes[a]=b},getAttribute:function(a){return this.attributes[a]||""},addParam:function(a,b){this.params[a]=b},getParams:function(){return this.params},addVariable:function(a,b){this.variables[a]=b},getVariable:function(a){return this.variables[a]||""},getVariables:function(){return this.variables},getVariablePairs:function(){var a=[];var b;var c=this.getVariables();for(b in c){a[a.length]=b+"="+c[b]}return a},getSWFHTML:function(){var d="";if(navigator.plugins&&navigator.mimeTypes&&navigator.mimeTypes.length){if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","PlugIn");this.setAttribute("swf",this.xiSWFPath)}d='<embed type="application/x-shockwave-flash" wmode="transparent" src="'+this.getAttribute("swf")+'" width="'+this.getAttribute("width")+'" height="'+this.getAttribute("height")+'" style="'+(this.getAttribute("style")||"")+'"';d+=' id="'+this.getAttribute("id")+'" name="'+this.getAttribute("id")+'" ';var c=this.getParams();for(var a in c){d+=[a]+'="'+c[a]+'" '}var b=this.getVariablePairs().join("&");if(b.length>0){d+='flashvars="'+b+'"'}d+="/>"}else{if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","ActiveX");this.setAttribute("swf",this.xiSWFPath)}d='<object id="'+this.getAttribute("id")+'" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="'+this.getAttribute("width")+'" height="'+this.getAttribute("height")+'" style="'+(this.getAttribute("style")||"")+'">';d+='<param name="movie" value="'+this.getAttribute("swf")+'" /><param name="wmode" value="transparent" />';var c=this.getParams();for(var a in c){d+='<param name="'+a+'" value="'+c[a]+'" />'}var b=this.getVariablePairs().join("&");if(b.length>0){d+='<param name="flashvars" value="'+b+'" />'}d+="</object>"}return d},write:function(a){if(this.getAttribute("useExpressInstall")){var b=new deconcept.PlayerVersion([6,0,65]);if(this.installedVer.versionIsValid(b)&&!this.installedVer.versionIsValid(this.getAttribute("version"))){this.setAttribute("doExpressInstall",true);this.addVariable("MMredirectURL",escape(this.getAttribute("xiRedirectUrl")));document.title=document.title.slice(0,47)+" - Flash Player Installation";this.addVariable("MMdoctitle",document.title)}}if(this.skipDetect||this.getAttribute("doExpressInstall")||this.installedVer.versionIsValid(this.getAttribute("version"))){var c=(typeof a=="string")?document.getElementById(a):a;c.innerHTML=this.getSWFHTML();return true}else{if(this.getAttribute("redirectUrl")!=""){document.location.replace(this.getAttribute("redirectUrl"))}}return false}};deconcept.SWFObjectUtil.getPlayerVersion=function(){var c=new deconcept.PlayerVersion([0,0,0]);if(navigator.plugins&&navigator.mimeTypes.length){var a=navigator.plugins["Shockwave Flash"];if(a&&a.description){c=new deconcept.PlayerVersion(a.description.replace(/([a-zA-Z]|\s)+/,"").replace(/(\s+r|\s+b[0-9]+)/,".").split("."))}}else{if(navigator.userAgent&&navigator.userAgent.indexOf("Windows CE")>=0){var d=1;var b=3;while(d){try{b++;d=new ActiveXObject("ShockwaveFlash.ShockwaveFlash."+b);c=new deconcept.PlayerVersion([b,0,0])}catch(f){d=null}}}else{try{var d=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7")}catch(f){try{var d=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6");c=new deconcept.PlayerVersion([6,0,21]);d.AllowScriptAccess="always"}catch(f){if(c.major==6){return c}}try{d=new ActiveXObject("ShockwaveFlash.ShockwaveFlash")}catch(f){}}if(d!=null){c=new deconcept.PlayerVersion(d.GetVariable("$version").split(" ")[1].split(","))}}}return c};deconcept.PlayerVersion=function(a){this.major=a[0]!=null?parseInt(a[0]):0;this.minor=a[1]!=null?parseInt(a[1]):0;this.rev=a[2]!=null?parseInt(a[2]):0};deconcept.PlayerVersion.prototype.versionIsValid=function(a){if(this.major<a.major){return false}if(this.major>a.major){return true}if(this.minor<a.minor){return false}if(this.minor>a.minor){return true}if(this.rev<a.rev){return false}return true};deconcept.util={getRequestParameter:function(d){var c=document.location.search||document.location.hash;if(d==null){return c}if(c){var b=c.substring(1).split("&");for(var a=0;a<b.length;a++){if(b[a].substring(0,b[a].indexOf("="))==d){return b[a].substring((b[a].indexOf("=")+1))}}}return""}};deconcept.SWFObjectUtil.cleanupSWFs=function(){var c=document.getElementsByTagName("OBJECT");for(var b=c.length-1;b>=0;b--){c[b].style.display="none";for(var a in c[b]){if(typeof c[b][a]=="function"){c[b][a]=function(){}}}}};if(!document.getElementById&&document.all){document.getElementById=function(a){return document.all[a]}}var getQueryParamValue=deconcept.util.getRequestParameter;var FlashObject=deconcept.SWFObject;var SWFObject=deconcept.SWFObject;




/**
		*Filename:      main.js
		*Version:       1.0.0(2009-03-02)
		*Website:       http://
		*Author:        S.S.L
		*Modify:        2009-07-16
		**/
function ue_tab( tab_menu,tab_main,cur_tab,mouse,time ){
		var pre_no;
		var timer;
		var tab;
		
		function $( id ){ return document.getElementById( id );}
		
		function run( no ){
		if( no != null ){
		if( timer != null )clearInterval( timer );
		timer = setInterval( function(){
		doChange(no);
		},200 );
		}
		}
		
		function addEvent(){
		for( var i = 0; i < tab.length; i++ ){
		tab[i].cur_no = i;
		if( mouse == null ){
		tab[i].onclick = function(){ 
		run( this.cur_no );
		}
		} else {
		tab[i].onmouseover = tab[i].onmouseout= function(){
		run( this.cur_no );
		}
		}
		}
		}
		
		function doChange( k ){
		if( tab[pre_no] != null && $(tab_main+(pre_no+1)) != null ){
		tab[pre_no].className = "off";
		$(tab_main+(pre_no+1)).style.display = "none";
		}
 if( tab[k] != null && $(tab_main+(k+1)) != null ){
		tab[k].className = "on";
		$(tab_main+(k+1)).style.display = "block";
		}
		
		pre_no = k;
		
		if( timer != null )clearInterval( timer );
		
		return false;
		}
		
		function init(){
		if( tab_menu == null || tab_main == null ) return;
		
		var tabs = tab_menu.split(" ");
		
		if( tabs[0] == null || tabs[1] == null || $( tabs[0] ) == null ) return;
		
		tab = $( tabs[0] ).getElementsByTagName( tabs[1] );
 pre_no = ( cur_tab == null ) ? 0:(cur_tab-1);
				
		doChange( pre_no );
		addEvent();
		}
		
		init();
}


/****************************************** 
 *AD
 ******************************************/
function mmoAds_deliverActiveX(content)
{
	document.write(content);	
}

/**
 *Filename:      gift center (tpl)
 *Version:       1.0.0(2009-12-22)
 *Author:        Bobby
**/
function bbgGiftCenter(){var cs = "<div class=\"hot_gift\"><div class=\"hot_gift_tit\"><h3>Gift Center</h3><div><a href=\"javascript:void(0)\" class=\"to_l\" onmouseup=\"x_scroll.stopToLeft()\" onmousedown=\"x_scroll.toLeft()\" onmouseout=\"x_scroll.stopToLeft()\" onclick=\"return false\"></a><a href=\"javascript:void(0)\" class=\"to_r\" onmouseup=\"x_scroll.stopToRight()\" onmousedown=\"x_scroll.toRight()\" onmouseout=\"x_scroll.stopToRight()\" onclick=\"return false\"></a></div><br class=\"clear\" /></div><div class=\"bd\"><div class=\"col1_2\" id=\"timescroll\"><div class=\"col1_2_1\"><div id=\"timescrllpage1\" class=\"left\"><ul class=\"hot_gift_list4\">" + document.getElementById("ue_hotgiftlist_con").innerHTML + "</ul></div><div id=\"timescrllpage2\" class=\"left\"></div><div class=\"clear\"></div></div></div><a class=\"btn_goto_gift\" href=\"http://contest.bbgsite.com/gift/\" title=\"More prizes at Gift Center!\">More prizes at Gift Center!</a></div></div>"; return cs;}

