var Flash={ detected:{}, version:[ 0, 0, 0 ], init:function(version) { if(!(version in Flash.detected)) Flash.detected[version]=Flash.detect(version); return Flash.detected[version]; }, detect:function(version) { var a=null; var d=''; if(/*@cc_on!@*/false){ try{ a=new ActiveXObject('ShockwaveFlash.ShockwaveFlash.'+version); if(version<=6) d='WIN 6,0,21,0'; a.AllowScriptAccess='always'; d=a.GetVariable('$version'); }catch(er){ if(version>6) return false; } if(!a) return false; if(d){ d=d.split(" ")[1].split(","); Flash.version=[ parseInt(d[0], 10), parseInt(d[1], 10), parseInt(d[2], 10) ]; } return true; }else if(navigator.plugins['Shockwave Flash']){ d=navigator.plugins['Shockwave Flash'].description; if(d){ d=d.replace(/^.*\s+(\S+\s+\S+$)/, "$1"); Flash.version[0]=parseInt(d.replace(/^(.*)\..*$/, "$1"), 10); Flash.version[1]=parseInt(d.replace(/^.*\.(.*)\s.*$/, "$1"), 10); Flash.version[2]=/r/.test(d)?parseInt(d.replace(/^.*r(.*)$/, "$1"), 10):0; } return (Flash.version[0] >= version); } return false; }, draw:function(src, width, height, bgcolor, vars, transparent, id, zindex) { var ret='<object id="'+id+'" name="'+id+'" style="z-index:'+(zindex||0)+'" type="application/x-shockwave-flash" width="'+width+'" height="'+height+'" '; if(/*@cc_on!@*/true) ret+=' data="'+src+'" '; ret+='>'; if(bgcolor) ret+='<param name="bgcolor" value="'+bgcolor+'" />'; if(vars){ if(typeof(vars)=='object'){ var v=[]; for(var key in vars){ v.push(key+"="+encodeURIComponent(vars[key])); } vars=v.join('&'); } ret+='<param name="FlashVars" value="'+vars+'" />'; } if(transparent) ret+='<param name="wmode" value="transparent" />'; if(/*@cc_on!@*/false) ret+='<param name="movie" value="'+src+'" />'; return ret+'<param name="allowFullScreen" value="true" />\ <param name="allowScriptAccess" value="always" />\ <param name="menu" value="false" />\ <param name="quality" value="high" />\ </object>'; }, get:function(f){ return (window[f]?window[f]:document[f]); } }; var JSRoot='\/\/images.badoo.com/1614/-/-/'; var $=window.$||function(el) { if(typeof(el)=='string') el=document.getElementById(el); return el || null; }; function add_css(cssCode) { var el=document.createElement("style"); el.type="text/css"; if(el.styleSheet) el.styleSheet.cssText=cssCode; else el.appendChild(document.createTextNode(cssCode)); document.getElementsByTagName("head")[0].appendChild(el); } if(Flash.init(9)) add_css('#maintable .wrap{visibility:hidden}'); function MainPage_init() { var el=$('error_close'); if(el) el.onclick=function(e){ var el=(e=e||event).target||e.srcElement; el.parentNode.parentNode.removeChild(el.parentNode); e.returnValue=false; e.cancelBubble=true; return false; }; if(Flash.init(9)){ $('maintable').className='flashon'; $('flash_pl').innerHTML=Flash.draw(JSRoot + 'flash/badooplanet/badooplanet.swf', "100%", 550, "#fff", $('planet_params').value, true, "fBadooPlanet");; } }