if(typeof(FIVEMIN)=="undefined"){var FIVEMIN={}}if(typeof(FIVEMIN.LIB)=="undefined"){FIVEMIN.LIB=(function(){FIVEMIN.LIB=function(){function g(){return g.getById.apply(this,arguments)}g.extend=function(i,j){for(var h in (j||{})){i[h]=j[h]}return i};var d;g.extend(g,{document:document,getById:function(i,h){return i?i.nodeName?i:(h||document).getElementById(i):null},create:function(h,j,k){var i=(k||g.document||document).createElement(h);if(j){g.alter(i,j)}return i},setDocument:function(h){d=g.document||document;g.document=h},restoreDocument:function(){g.document=d;d=null},alter:function(h,i){if(!i){return}if(i.styles){g.css(h,i.styles);delete i.styles}if(i.events){g.each(i.events,function(k,l){g.addEvent(h,l,k)});delete i.events}if(i.children){g.each(i.children,function(k){h.appendChild(k)});delete i.children}var j=i.parent;delete i.parent;g.extend(h,i);if(j){j.appendChild(h)}return h},removeNode:function(h){if(h.parentNode){h.parentNode.removeChild(h)}},getElement:function(h,i){return g.getElements(h,i)[0]},getElements:function(s,o){if(!o){o=g.document}var k=[];if(s.indexOf(".")>-1){for(var r=s.split("."),h=new RegExp("\\b"+r[1]+"\\b"),l=o.getElementsByTagName(r[0]||"*"),n=l.length,q=0,m=0,p;q<n;++q){p=l[q];if(h.test(p.className)){k[m++]=p}}}else{k=g.toArray(o.getElementsByTagName(s))}return k},hasChild:function(i,h){if(g.browser.engine=="webkit"&&g.browser.version<420){return g.indexOf(g.toArray(i.getElementsByTagName(h.tagName)),h)>-1}return i.contains?i!=h&&i.contains(h):!!(i.compareDocumentPosition(h)&16)},addEvent:document.attachEvent?function(h,j,i){h.attachEvent("on"+j,i)}:function(h,j,i){h.addEventListener(j,i,false)},removeEvent:document.detachEvent?function(h,j,i){h.detachEvent("on"+j,i)}:function(h,j,i){h.removeEventListener(j,i,false)},stopEvent:function(i,j,h){if(j!==false){if(i.preventDefault){i.preventDefault()}else{i.returnValue=false}}if(h!==false){if(i.stopPropagation){i.stopPropagation()}else{i.cancelBubble=true}}},eventElement:function(h){return h.target?h.target:h.srcElement},toArray:function(m){if(m instanceof Array){return m}if(m.item){var h=[];for(var j=0,k=m.length;j<k;j++){h[j]=m[j]}return h}return Array.prototype.slice.call(m)},indexOf:function(m,k,h){var l=m.length;for(var j=(h<0)?Math.max(0,l+h):h||0;j<l;j++){if(m[j]===k){return j}}return -1},removeItem:function(k,j){for(var h=k.length;h--;){if(k[h]===j){k.splice(h,1)}}},each:function(m,k,l){if(m instanceof Array){for(var j=0;j<m.length;j++){k.call(l||null,m[j],j)}}else{for(var h in m){k.call(l||null,m[h],h)}}return m},trim:function(h){return h.replace(/^\s+|\s+$/g,"")},time:function(){return new Date().getTime()},map:function(k,h,i){var j=k instanceof Array?[]:{};g.each(k,function(m,l){j[l]=h.call(i||null,m,l)});return j},css:function(h,i){if(typeof(i)=="string"){h.style.cssText=i}else{if(i.opacity!==undefined){g.opacity(h,i.opacity);delete i.opacity}i=g.map(i,function(k,j){if(g.indexOf(c,j)!=-1){return parseFloat(k)}if(g.indexOf(b,j)!=-1&&typeof(k)=="number"){return k+"px"}return k});g.extend(h.style,i)}return h},docSize:function(j){var h=0,i=0;if(self.innerHeight){h=window.innerHeight;i=window.innerWidth}else{if(j.documentElement&&j.documentElement.clientHeight){h=j.documentElement.clientHeight;i=j.documentElement.clientWidth}else{if(document.body){h=j.body.clientHeight;i=j.body.clientWidth}}}if(h<j.body.clientHeight){h=j.body.clientHeight}return{height:parseInt(h,10),width:parseInt(i,10)}},addCls:function(h,i){if(!g.hasCls(h,i)){h.className+=" "+i}},removeCls:function(h,i){h.className=h.className.replace(new RegExp("(^|\\s+)"+i+"(\\s+|$)","g")," ")},hasCls:function(h,i){return new RegExp("(^|\\s)"+i+"(\\s|$)").test(h.className)},currCss:function(h,i,l){if(i=="float"){i="cssFloat"}if(i=="opacity"&&g.browser.engine=="ie"){return g.opacity(h)}var j=null;if(h.currentStyle){j=h.currentStyle[i.replace(/-\D/g,function(n){return n.charAt(1).toUpperCase()})]}else{var m=h.ownerDocument.defaultView.getComputedStyle(h,null);j=m?m.getPropertyValue(i):null}if(j=="auto"&&(i=="width"||i=="height")){j=h["offset"+i.charAt(0).toUpperCase()+i.substr(1)];var k=i=="width"?["left","right"]:["top","bottom"];j-=g.currCss(h,k[0])+g.currCss(h,k[1]);if(j<0){j=0}}if(j!==null&&(g.indexOf(b,i)!=-1||g.indexOf(c,i)!=-1||l||j.indexOf("px")==j.length-2)){j=parseFloat(j)}return j},opacity:function(h,j){if(j===undefined){if(g.browser.engine!="ie"){return g.currCss(h,"opacity")}var i=h.style.filter;return i&&i.indexOf("opacity=")>=0?(parseFloat(i.match(/opacity=([^)]*)/)[1])/100):1}else{if(j==0){if(h.style.visibility!="hidden"){h.style.visibility="hidden"}}else{if(h.style.visibility!="visible"){h.style.visibility="visible"}}if(!h.currentStyle||!h.currentStyle.hasLayout){h.style.zoom=1}if(g.browser.engine=="ie"){h.style.filter=j==1?"":"alpha(opacity="+j*100+")"}h.style.opacity=j}},bind:function(h,i){return function(){h.apply(i,arguments)}},htmlenc:function e(h){return h?h.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/'/g,"&apos;").replace(/"/g,"&quot;"):""},log:function(){if(typeof(console)=="undefined"){return}try{console.log.apply(console,arguments)}catch(h){console.log(g.toArray(arguments))}},prepend:function(h,j){var i=h.firstChild;if(typeof i!="undefined"){h.insertBefore(j,i)}else{h.appendChild(j)}},timer:function(){var h;return{start:function(){h=new Date().getTime()},getStatus:function(){var j=new Date().getTime();var i=(j-h)/1000;return i}}}(),isDecendant:function(i,j){var h=false;do{if(i==j){h=true;break}i=i.parentNode}while(i.tagName.toLowerCase()!="html");return h}});g.browser={};(function(){if(navigator.userAgent.indexOf("MSIE")>-1){g.browser.engine="ie";g.browser.version=window.XMLHttpRequest?7:6}else{if(navigator.userAgent.indexOf("Gecko/")>-1){g.browser.engine="gecko";g.browser.version=window.getElementsByClassName?19:18}else{if(navigator.userAgent.indexOf("AppleWebKit/")>-1){g.browser.engine="webkit";g.browser.version=!!document.evaluate?(!!document.querySelector?525:420):419}}}})();(function(){var h,i=[];g.extend(g,{addDomReady:function(l){if(h){return l()}i[i.length]=l;if(!k){k=true;j()}}});var k;function j(){if(g.browser.engine=="ie"){var m=g.create("div");(function(){var n;try{m.doScroll("left");g.document.body.appendChild(m);m.innerHTML="temp";g.removeNode(m);n=true}catch(o){setTimeout(arguments.callee,500)}if(n){l()}})()}else{if(g.browser.engine=="webkit"&&g.browser.version<525){(function(){if(g.document.readyState=="loaded"||g.document.readyState=="complete"){l()}else{setTimeout(arguments.callee,500)}})()}else{g.addEvent(window,"load",l);g.addEvent(document,"DOMContentLoaded",l)}}function l(){if(h){return}h=true;g.each(i,function(n){n()})}}})();var f=5;var b="left,top,bottom,right,width,height,maxWidth,maxHeight,minWidth,minHeight,fontSize,letterSpacing,lineHeight,margin,marginLeft,marginRight,marginTop,marginBottom,padding,paddingLeft,paddingRight,paddingTop,paddingBottom,borderWidthLeft,borderWidthRight,borderWidthTop,borderWidthBottom".split(",");var c="z-index,font-weight,opacity,zoom,line-height".split(",");return g}();var a=FIVEMIN.LIB;FIVEMIN.LIB.Fx=function(){var c={duration:500,fps:50};function b(e,d){this.element=e;this.options=a.extend(a.extend({},c),d)}b.prototype={transition:function(d){return -(Math.cos(Math.PI*d)-1)/2},start:function(d){if(this.timer){return false}this.to=d;this.from=this.getFrom();this.startTime=a.time();this.endTime=this.startTime+this.options.duration;this.timer=setInterval(a.bind(this.step,this),Math.round(1000/this.options.fps));return this},stop:function(){if(!this.timer){return false}clearInterval(this.timer);this.timer=null},cancel:function(){this.stop();if(this.options.onCancel){this.options.onCancel.call(this)}},complete:function(){this.set(1);this.stop();if(this.options.onComplete){this.options.onComplete.call(this)}},step:function(){var e=a.time();if(e<this.endTime){var d=this.transition((e-this.startTime)/this.options.duration);this.set(d)}else{this.complete()}},getFrom:function(e){var d={};a.each(this.to,function(g,f){d[f]=a.currCss(this.element,f);if(f=="marginLeft"&&isNaN(d[f])){d[f]=a.currCss(this.element,"margin-left")}},this);return d},set:function(d){var e={};a.each(this.to,function(g,f){e[f]=(g-this.from[f])*d+this.from[f];if(f!=="opacity"){e[f]=Math.floor(e[f])}},this);a.css(this.element,e)}};return b}();return FIVEMIN.LIB})()}if(typeof(FIVEMIN.ThumbSeed)=="undefined"){FIVEMIN.ThumbSeed=function(){var w=FIVEMIN.LIB;w.fx=FIVEMIN.LIB.Fx;var A=/http:\/\/(\w?)shared\.5min\.com\/scripts\/thumbseed2?\.js\?/i;var f="fmts-";var s=c("fmts-headercolor","#666666"),d=c("fmts-bgcolor","#ffffff"),C=c("fmts-bgcolor","#000000"),F=c("fmts-textlocation","0"),J=c("fmts-ht","1");var D="fmtsw";var m="fmtsw";var b,n=true;function r(O){var P=O.split(",");return P[Math.floor(Math.random()*P.length)]}var i="http://www.5min.com/",h="http://syn.5min.com/",H="http://pshared.5min.com/",x="http://pshared.5min.com/Graphics/Thumbseed/",N="http://pfiles.5min.com/flashproxy/";var g=false;switch(c("fmts-test")){case"netcraft":i="http://www.5min.com/";h="http://syn.5min.com/";H="http://localhost/Thumbseed/";x="http://localhost/Thumbseed/Graphics/Thumbseed/";N="http://localhost/Thumbseed/Scripts/";A=/\/scripts\/thumbseed2?\.js\?/i;g=true;break;case"localhost":i="http://localhost/5min/";h="http://localhost/syn/";H="http://localhost/Shared/";N="http://localhost/Files/flashproxy/";A=/\/scripts\/thumbseed2?\.js\?/i;g=true;break;case"5minlocal":i="http://www.5min.com/";h="http://syn.5min.com/";H="http://shared.5min.com/";A=/\/scripts\/thumbseed2?\.js\?/i;g=true;break}function t(){return w.getElement("head")||w.document.body||w.document.documentElement}var G=function(){var O;return{init:function(){if(w.browser.engine=="ie"){O=document.createStyleSheet()}else{O=document.createElement("style");O.type="text/css";t().appendChild(O)}},addRule:function(S,P){if(w.browser.engine=="ie"){if(S.indexOf(",")>-1){var Q=S.split(",");for(var T=0;T<Q.length;T++){O.addRule(Q[T],P)}}else{O.addRule(S,P)}}else{var R=S+"{"+P+"}";O.appendChild(document.createTextNode(R))}},clear:function(){O.innerHTML=""}}}();var e="";function y(O,Q){var P=this;this.wrapper=(typeof O=="string")?w.getById(O):O;this.initiatorScriptTag=Q;this.instanceNumber=y._instances.length;y._instances.push(this)}var k=false,B=false,L=[];w.extend(y,{_instances:[],getTopMostWindow:function(){var O=window;while(O){try{var R=O.parent;var Q=R.document;if(!Q){break}O=R;if(R==R.parent){break}}catch(P){break}}y.getTopMostWindow=function(){return O};return O},addCssFile:function(O){if(k){O();return}L.push(O);if(!B){B=true;l(H+"Scripts/ThumbSeed2.Style.js",null,{preventCache:false})}return},putThumbSeedCss:function(O,Q){var P=[O];if(!this.customCss){P.push(Q)}this.putCss(P.join(" "))},putCss:function(P){this.putCssOnDocument(w.document,P);var O=y.getTopMostWindow();if(O!=window){this.putCssOnDocument(y.getTopMostWindow().document,P)}k=true;if(g){w.log("_cssAdded=true "+w.timer.getStatus())}setTimeout(function(){w.each(L,function(Q){Q()})},50)},putCssOnDocument:function(T,P){w.setDocument(T);if(g){w.log("putCssOnDocument "+w.timer.getStatus())}if(w.browser.engine=="ie"){var O='<span>DumbIE</span><style type="text/css">'+P+"</style>";var Q=w.create("div",{innerHTML:O});var S=t(T);S.appendChild(Q.lastChild)}else{var R=w.create("style",{type:"text/css",parent:t(),textContent:P})}w.restoreDocument()}});w.extend(y.prototype,{load:function(){if(g){w.log("ThumbSeed#load",this)}this.setStyleProperties();this.innerWrapper=w.create("div",{className:f+"wrapper clearfix",id:f+"wrapper-"+this.instanceNumber});w.addCls(this.innerWrapper,f+w.browser.engine);if(document.compatMode=="BackCompat"){w.addCls(this.innerWrapper,f+"quirksmode")}if(g){w.log("created innerWrapper",this.innerWrapper)}var O=function(Q){Q.wrapper.appendChild(Q.innerWrapper);Q._drawn=false;if(Q.fallback){Q.showLoadIndicator()}Q.requestData();if(y.loadedMainStyle==true){k=true;if(g){w.log("###loadedMainStyle = true")}}else{if(g){w.log("###loadedMainStyle = false")}y.addCssFile(w.bind(function(){Q.showContent()},Q))}};var P=this;if(w.browser.engine=="ie"){if(typeof this.initiatorScriptTag=="undefined"){if(g){w.log("ThumbSeed initiated not using querystring. Continuing after dom ready.")}w.addDomReady(function(){O(P)})}else{if(w.isDecendant(this.initiatorScriptTag,this.wrapper)){if(g){w.log("Script tag is within the wrapper . Continuing after dom ready.")}w.addDomReady(function(){O(P)})}else{w.log("Script tag is not the wrapper.");O(P)}}}else{O(P)}},requestData:function(){if(!this.url){this.url=location.href;var P=y.getTopMostWindow();this.url=P.location.href}var R={requestURL:h+"handlers/SenseHandler.ashx?func=GetResults&thumbSeedCounter="+this.instanceNumber+"&sid="+this.sid+this.getParamsForHandler()+"&url="+encodeURIComponent(this.url)+"&isnewts=true",jscbRequest:this.onHandlerResponse,instanceNumber:this.instanceNumber,parentEls:[this.wrapper]};if(location.href.indexOf("life123.com")!==-1){var O=document.getElementById("fivemin");R.parentEls.push(O)}try{this.flashProxy.init(R)}catch(Q){if(g){alert(Q)}}if(g){w.log("requesting data")}},onHandlerResponse:function(O,Q){if(g){w.log("received data","success="+O)}if(O==2){return}if(g&&typeof localdata!="undefined"){Q=localdata}if(g){w.log("data=",Q)}if(Q&&Q.binding){this.serverData=this._normalizeServerData(Q);this.videos=Q.binding;this.draw();if(n&&typeof this.directURL=="undefined"&&typeof b=="undefined"){if(w.browser.engine=="ie"){if(g){w.log("adding lightbox creation to dom ready")}var P=this;w.addDomReady(w.bind(function(){this.createLightBox()},this));n=false}else{this.createLightBox()}}}},createLightBox:function(){if(g){w.log("creating lightbox")}b=new p();b.init({lightboxAnim:this.serverData.lightboxAnim,overlayOpacity:this.serverData.overlayOpacity,overlayColor:this.serverData.overlayColor,show5minLink:this.serverData.by5minLink,show5minText:this.serverData.by5minText},this.instanceNumber)},flashProxy:function(){return{init:function(R){for(var O=0;O<R.parentEls.length;O++){w.css(R.parentEls[O],{display:"block"})}var P=w.create("div",{innerHTML:this.getHTML(R),className:f+"flashproxy",styles:{position:"absolute",top:0,left:0}});var Q=w.getElement("body");Q.insertBefore(P,Q.firstChild)},getHTML:function(P){var O;var Q=N+"flashproxy.swf?";Q+="requestURL="+encodeURIComponent(P.requestURL);Q+="&jscbRequest=ThumbSeed._instances["+P.instanceNumber+"].onHandlerResponse";if(w.browser.engine=="ie"&&w.browser.version==6){Q+="&nocache="+Math.random(1000)}if(w.browser.engine=="ie"){O='<object id="FiveminFlashProxy" width="0" height="0" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000"><param name="allowScriptAccess" value="always"><param name="movie" value="'+Q+'"></object>'}else{O='<embed name="FiveminFlashProxy" src="'+Q+'" type="application/x-shockwave-flash" width="0" height="0" allowScriptAccess="always"></embed>'}if(g){w.log("flash source ="+Q)}if(g){w.log("flash html ="+O)}return O}}}(),onRelatedVideoChanged:function(O){if(typeof b!="undefined"){b.setTitle(O.title);b.updateSharingLinks(O.title,O.pageUrl)}},showBottomAd:function(){if(typeof b!="undefined"){b.showBottomAd()}},getPlayListURL:function(){var Q=[];var P=function(V){var S=parseInt(V.split(":")[0],10);var U=parseInt(V.split(":")[1],10);var T=S*60+U;return T};var R=function(T){var S={};for(key in T){S[key]=T[key]}return S};for(var O=0;O<this.videos.length;O++){Q.push(R(this.videos[O]));Q[O].Duration=P(Q[O].Duration);Q[O].Image=Q[O].ThumbURL}return Q},setStyleProperties:function(){if(this.layout){this.convertLayout();this.convertColors()}if(this.serverData!=null){switch(this.thumbnailSize.toString()){case"0":this.playButtonImg=this.playButtonImg?this.playButtonImg:this.serverData.playButtonImg;this.playButtonImg_MO=this.playButtonImg_MO?this.playButtonImg_MO:this.serverData.playButtonImg_MO;break;case"1":case"2":this.playButtonImg=this.SmallPlayButton?this.SmallPlayButton:this.serverData.SmallPlayButton;this.playButtonImg_MO=this.SmallPlayButtonMouseOver?this.SmallPlayButtonMouseOver:this.serverData.SmallPlayButtonMouseOver;break}var O=new Image();O.src=this.playButtonImg;var P=new Image();P.src=this.playButtonImg_MO;if(this.headerTextColor==null&&this.serverData.headerTitleColor){this.headerTextColor=this.serverData.headerTitleColor}if(this.headerBorderColor==null&&this.serverData.headerBorderColor){this.headerBorderColor=this.serverData.headerBorderColor}if(this.headerTitleFont==null&&this.serverData.headerTitleFont){this.headerTitleFont=this.serverData.headerTitleFont}if(this.textFGColor==null&&this.serverData.textFGColor){this.textFGColor=this.serverData.textFGColor}if(this.textFGColor_MO==null&&this.serverData.textFGColor_MO){this.textFGColor_MO=this.serverData.textFGColor_MO}if(this.textBGColor==null&&this.serverData.textBGColor){this.textBGColor=this.serverData.textBGColor}if(this.textBGColor_MO==null&&this.serverData.textBGColor_MO){this.textBGColor_MO=this.serverData.textBGColor_MO}if(this.thumbnailTitleFont==null&&this.serverData.thumbnailTitleFont){this.thumbnailTitleFont=this.serverData.thumbnailTitleFont}this.headerTextColor=this.headerTextColor?this.headerTextColor.toLowerCase():s;this.headerBorderColor=this.headerBorderColor?this.headerBorderColor.toLowerCase():this.headerTextColor;this.textFGColor=this.textFGColor?this.textFGColor.toLowerCase():d;this.textFGColor_MO=this.textFGColor_MO?this.textFGColor_MO.toLowerCase():d;this.textBGColor=this.textBGColor?this.textBGColor.toLowerCase():C;this.textBGColor_MO=this.textBGColor_MO?this.textBGColor_MO.toLowerCase():C;this.headerTextColor=this.convertToHex(this.headerTextColor);this.headerBorderColor=this.convertToHex(this.headerBorderColor);this.textFGColor=this.convertToHex(this.textFGColor);this.textFGColor_MO=this.convertToHex(this.textFGColor_MO);this.textBGColor=this.convertToHex(this.textBGColor);this.textBGColor_MO=this.convertToHex(this.textBGColor_MO);this.textLocation=this.textLocation?this.textLocation:F}},convertLayout:function(){this.layout=this.layout.toLowerCase();var O=this.layout.split("x");this.width=O[0];this.height=O[1];this.thumbnailSize=2;if(this.layout=="300x250"||this.layout=="250x250"||this.layout=="728x90"||this.layout=="590x96"||this.layout=="575x100"||this.layout=="468x60"||this.layout=="205x335"){this.textLocation=0}else{this.textLocation=1}if(this.layout=="300x250"||this.layout=="250x250"||this.layout=="700x180"||this.layout=="468x200"||this.layout=="160x600"||this.layout=="500x175"||this.layout=="425x400"||this.layout=="120x120"){this.thumbnailSize=1}else{if(this.layout=="468x544"){this.thumbnailSize=0}else{this.thumbnailSize=2}}this.BW_layout=this.layout;this.layout=null},convertColors:function(){if(this.backgroundColor){this.backgroundColor=this.backgroundColor.toLowerCase()}else{if(this.backGroundColor){this.backgroundColor=this.backGroundColor.toLowerCase()}else{this.backgroundColor="white"}}if(this.headerColor){this.headerColor=this.headerColor.toLowerCase()}if(this.backgroundColor==="black"){this.headerTextColor=(!this.headerColor||this.headerColor==="black")?"#656565":this.headerColor;this.textFGColor="#ffffff";this.textBGColor=(!this.headerColor)?"#000000":this.headerColor;this.textFGColor_MO="#ffffff";this.textBGColor_MO=(!this.headerColor||this.headerColor==="black")?"#656565":"#000000"}else{if(this.backgroundColor==="grey"||this.backgroundColor==="gray"){this.headerTextColor=(!this.headerColor||this.headerColor==="black")?"#656565":this.headerColor;this.textFGColor=(!this.headerColor)?"#000000":this.headerColor;this.textBGColor="#ffffff";this.textFGColor_MO="#ffffff";this.textBGColor_MO=(!this.headerColor)?"#000000":this.headerColor}else{this.headerTextColor=(!this.headerColor||this.headerColor==="black"||this.headerColor==="white")?"#656565":this.headerColor;this.textFGColor=(!this.headerColor||this.headerColor==="white")?"#000000":this.headerColor;this.textBGColor="#ffffff";this.textFGColor_MO="#ffffff";this.textBGColor_MO=(!this.headerColor||this.headerColor==="white")?"#000000":this.headerColor}}},convertToHex:function(O){O=O.toLowerCase();switch(O){case"blue":O="#006699";break;case"grey":O="#656565";break;case"green":O="#2e7720";break;case"orange":O="#ff6600";break;case"red":O="#cc0000";break;case"purple":O="#592e7b";break;case"light blue":O="#79b0cb";break}return O},convertEnum:function(P,O){var Q;switch(O){case"ht":switch(P){case 0:case"0":Q="_self";break;case 1:case"1":Q="_blank";break}break}return Q},showContent:function(){if(g){w.log("showContent "+w.timer.getStatus());w.log("_cssAdded="+k+" drawn="+this._drawn)}if(k&&this._drawn){this.hideLoadIndicator()}},showLoadIndicator:function(){w.css(this.innerWrapper,{width:this.width+"px",height:this.height+"px",background:"url("+x+"preloader_big.gif) no-repeat center"});if(this.container){w.css(this.container,{visibility:"hidden"})}if(this.ad){w.css(this.ad,{visibility:"hidden"})}w.css(this.wrapper,{display:"block"})},hideLoadIndicator:function(){w.css(this.innerWrapper,{width:"",height:"",background:""});w.css(this.container,{visibility:"visible"});if(this.ad){w.css(this.ad,{visibility:"visible"})}},getParamsForHandler:function(){var P={};if(this.categories&&this.categories.length>0){P.categories=this.categories}if(this.playList&&this.playList.length>0){P.playlist=this.playList}if(this.featured&&this.featured==true){P.featured=true}if(this.explicitTags){P.explicitTags=this.explicitTags}if(this.fallback){P.fallback=this.fallback}if(this.fallbackType){P.fallbackType=this.fallbackType}if(this.contentQuality&&this.contentQuality>0){P.ContentQuality=this.contentQuality}if(this.libraryID>0){P.libraryID=this.libraryID}if(this.textLocation){P.textLocation=this.textLocation}if(this.thumbnailSize){P.thumbnailSize=this.thumbnailSize}if(this.testData){P.testData=this.testData}if(this.trackingText){P.trackingText=this.trackingText}this.setAdUnitLocation();if(this.adUnit){P.adUnit=this.adUnit;P.adUnitWidth=this.adUnitWidth;P.adUnitHeight=this.adUnitHeight;P.adUnitLocation=this.adUnitLocation}P.width=this.width;P.height=this.height;this.dimensionSettings=this._getLayoutSettings();if(this.dimensionSettings.numOfThumbs>0){P.NumOfThumbs=this.dimensionSettings.numOfThumbs}P.NumOfColumnsAsked=this.dimensionSettings.videoColCount;P.NumOfRowsAsked=this.dimensionSettings.videoRowCount;if(this.playButtonImg){P.playButtonImg=this.playButtonImg}var O="&"+M(P);return O},draw:function(){if(this._drawn||!this.videos){return}w.timer.start();this.setStyleProperties();if(g){w.log("draw started "+w.timer.getStatus())}w.css(this.wrapper,{display:"block"});if(this.wrapperToShow){this.wrapperToShowToDisplay=this.wrapperToShow.split(",");for(var O=0;O<this.wrapperToShowToDisplay.length;O++){w.css(w.getById(this.wrapperToShowToDisplay[O]),{display:"block"})}}G.init();this.container=w.create("div",{id:m,className:D+" "+f+"c",styles:{visibility:"hidden"}});if(this.serverData.showHeaderFooter){var S=this.drawHeader();this.setHeader(this.headerTextColor,this.headerTitleFont,this.headerBorderColor)}this.videoContainer=w.create("div",{parent:this.container,className:f+"vc"});this.videosList=w.create("ul",{parent:this.videoContainer,className:f+"vl clearfix"});this.innerWrapper.appendChild(this.container);w.addCls(this.container,f+"loading");var P;if(this.serverData.showHeaderFooter){P=this.draw5minElements();if(this.dimensionSettings.tsWidth>=300){S.appendChild(P);w.css(S,{paddingRight:"92px"})}else{var R=this.drawFooter();R.appendChild(P)}}this.drawAd();this.setTextLocation(this.textLocation);if(g){w.log("drawVideos "+w.timer.getStatus())}this.drawVideos(this.dimensionSettings);if(g){w.log("drawCarouselNav "+w.timer.getStatus())}if(this.serverData.showHeaderFooter&&this.dimensionSettings.carouselColCount>1){var Q=this.drawCarouselNav(P);this.carousel=new u();this.carousel.init({videos:this.videoObjects,parent:this.videoContainer,listEl:this.videosList,listHeight:this.dimensionSettings.overallHeight,moveBy:this.dimensionSettings.carouselColWidth,itemCount:this.dimensionSettings.carouselColCount,videosInColCount:this.dimensionSettings.videosInColCount,numOfVideosLoaded:this.dimensionSettings.numOfVideosLoaded,previousButton:Q.previousButton,nextButton:Q.nextButton,duration:600})}else{w.css(this.videoContainer,{height:this.dimensionSettings.overallHeight+"px"})}this._drawn=true;this.showContent();if(g){w.log("draw complete"+w.timer.getStatus())}},redraw:function(O){w.extend(this,O);if(g){for(key in O){w.log("newParam["+key+"]="+O[key])}}this.setStyleProperties();this.showLoadIndicator();this.destroy();this.setAdUnitLocation();this.dimensionSettings=this._getLayoutSettings();this._drawn=false;this.draw()},destroy:function(){if(this.carousel){this.carousel.destroy();this.carousel=null}if(this.videoObjects){for(var O=0;O<this.videoObjects.length;O++){this.videoObjects[O].destroy();this.videoObjects[O]=null}}this.innerWrapper.innerHTML="";this.container=this.footer=this.header=this.fiveMinElements=this.titleElement=this.videoContainer=this.videoList=this.videoObjects=this.ad=null},_normalizeServerData:function(P){var O=P;O.showHeaderFooter=(typeof P.showHeaderFooter!="undefined")?P.showHeaderFooter:true;O.by5minLink=(typeof P.by5minLink!="undefined")?P.by5minLink:true;O.by5minText=(typeof P.by5minText!="undefined")?P.by5minText:true;O.overlayOpacity=(P.lightBoxOpac)?P.lightBoxOpac:75;O.overlayColor=(P.lightBoxBGColor)?P.lightBoxBGColor:"black";if(typeof this.displayHeader!="undefined"){O.showHeaderFooter=this.displayHeader}return O},_getLayoutSettings:function(){var R={},O=5,P=11,S=21;R.initialVideoSize=this._getItemRelevantSize();R.isTextVertical=(this.textLocation==1);R.numOfThumbs=(this.videoCount)?this.videoCount:-1;R.tsWidth=this._getTSWidth(this.width,this.BW_layout,R.numOfThumbs);w.extend(R,this._getAdditionalLayoutSettings(R.initialVideoSize,R.tsWidth,O,R.isTextVertical,R.numOfThumbs));var Q=this._getActualContainerHeight(R.tsWidth,S);R.videoRowCount=this._getVideoRowCount(R.initialVideoSize,Q,P,R.isTextVertical);R.videosInColCount=R.videoRowCount*R.videoColCount;numOfRows=this._getNumOfRows(R.videoColCount,R.numOfThumbs);R.overallHeight=this._getOverallHeight(R.initialVideoSize,R.videoRowCount,numOfRows,P,R.isTextVertical,numOfRows);return R},_getActualContainerHeight:function(R,P){var O=parseInt(this.height,10);var Q=(R<300);if(Q){O=O-P}return O},_getTSWidth:function(O,R,P){var Q=parseInt(O,10);O=Q;if(P>0&&typeof R!="undefined"){Q=this._BW_resizeByItemCount(O);if(isNaN(Q)){Q=O}if(this.BW_layout=="728x90"||this.BW_layout=="590x96"||this.BW_layout=="575x100"||this.BW_layout=="468x60"){Q+=60}if(this.BW_layout=="728x90"){Q+=8}else{if(this.BW_layout=="590x96"){Q+=5}else{if(this.BW_layout=="575x100"){Q+=23}else{if(this.BW_layout=="500x175"){Q+=-4}else{if(this.BW_layout=="205x335"){Q=205}else{if(this.BW_layout=="120x120"){Q=120}else{if(this.BW_layout=="300x250"||this.BW_layout=="250x250"){Q=O}}}}}}}}return Q},_getNumOfRows:function(P,O){if(O==-1){return O}var Q=O/P;Q=Math.ceil(Q);return Q},_getAdditionalLayoutSettings:function(R,Q,T,P,O){var U={};summedWidth=0;U.videoColCount=0;U.spaceWidth=T;videoWidth=(P)?R.width:R.width+R.textWidth;do{U.videoColCount++;summedWidth=U.videoColCount*videoWidth+(U.videoColCount-1)*T;if(!(summedWidth<Q)){U.videoColCount--}}while(summedWidth<Q&&(U.videoColCount<O||O==-1));summedWidth=U.videoColCount*videoWidth+(U.videoColCount-1)*T;if(U.videoColCount>1){if(P){var S=(Q-summedWidth)/(U.videoColCount-1);S=parseInt(S,10);U.spaceWidth=U.spaceWidth+S;U.addToLast=(Q-summedWidth)%(U.videoColCount-1)}else{if(!P){var S=(Q-summedWidth)/(U.videoColCount);S=parseInt(S,10);U.textWidth=R.textWidth+S;U.addToLast=(Q-summedWidth)%(U.videoColCount)}}U.carouselColWidth=Q+U.spaceWidth}else{U.videoColCount=1;U.addToLast=0;if(Q<videoWidth){if(!P){U.textWidth=R.textWidth}U.carouselColWidth=videoWidth+U.spaceWidth}else{if(!P){U.textWidth=Q-R.width}U.carouselColWidth=Q+U.spaceWidth}}return U},_getVideoRowCount:function(R,P,O,U,S){var V=0;do{V++;var Q=(U)?R.height+R.textHeight:R.height;var T=O+(Q+O)*V}while(T<P);if(V>1){V=V-1}return V},_getOverallHeight:function(R,T,P,O,Q){P=(P>0&&P<T)?P:T;var S=P*(R.height+O);S=(Q)?S+P*(R.textHeight):S;return S},_getItemRelevantSize:function(){var O={};switch(this.thumbnailSize){case 0:case"0":O.width=148;O.height=111;O.textWidth=152;O.textHeight=48;break;case 1:case"1":O.width=109;O.height=81;O.textWidth=91;O.textHeight=48;break;case 2:case"2":O.width=84;O.height=63;O.textWidth=89;O.textHeight=48;break}return O},_BW_getVideoCount:function(){var Q=this._BW_getMaximumVideoCountForLayout();if(this.videos){if(this.videoCount&&this.videoCount>0){return Math.min(this.videoCount,this.videos.length,Q)}return Math.min(this.videos.length,Q)}var P=!this.videoCount||this.videoCount>Q?Q:this.videoCount;var O=this._BW_getPossibleVideoCountsForLayout();if(O&&w.indexOf(O,P)==-1){P=Q}return P},_BW_getMaximumVideoCountForLayout:function(){var O;switch(this.BW_layout){case"160x600":case"700x180":O=5;break;case"728x90":case"205x335":case"500x175":O=4;break;case"590x96":case"575x100":O=3;break;case"468x60":case"250x250":case"300x250":O=2;break;case"120x120":O=1;break;case"425x400":O=9;break;default:O=5;break}return O},_BW_resizeByItemCount:function(R){var O=this._BW_getMaximumVideoCountForLayout(),P=this._BW_getVideoCount();size=this._BW_getItemRelevantSize();if(g){w.log("_BW_getItemRelevantSize = ",size)}if(size){var Q={};var S=parseInt(R,10);if(this.BW_layout=="425x400"){O=3;P=Math.ceil(P/3)}Q[size.property]=S-(size[size.property]*(O-P));Q[size.property]=size[size.property]*P;if(size.property=="height"){Q.width=size.width}else{Q.height=size.height}if(this.BW_layout=="425x400"){P=this._BW_getVideoCount();Q.width*=(P>=3)?3:P%3}return Q.width}},_BW_getItemRelevantSize:function(){var O={property:"width"};switch(this.BW_layout){case"300x250":O.property="height";O.height=96;O.width=298;break;case"250x250":O.property="height";O.height=96;O.width=248;break;case"160x600":O.property="height";O.height=110;O.width=160;break;case"728x90":O.width=165;O.height=62;break;case"700x180":O.width=140;O.height=125;break;case"205x335":O.property="height";O.height=77;O.width=198;break;case"590x96":O.width=175;O.height=66;break;case"500x175":O.width=126;O.height=119;break;case"575x100":O.width=164;O.height=69;break;case"468x60":O.width=204;O.height=44;break;case"425x400":O.property="height";O.height=126;O.width=143;break}return O},_BW_getPossibleVideoCountsForLayout:function(){function P(Q,S){var T=[];for(var R=Q;R<=S;R++){T.push(R)}return T}var O;switch(this.BW_layout){case"300x250":case"250x250":O=P(1,2);break;case"160x600":O=P(1,5);break;case"728x90":O=P(1,4);break;case"700x180":O=P(2,5);break;case"590x96":O=P(1,3);break;case"500x175":O=P(1,4);break;case"575x100":O=P(1,3);break;case"468x60":O=P(1,2);break;case"425x400":O=[3,6,9];break;case"205x335":O=P(1,4);break;case"120x120":O=[1];break}return O},drawHeader:function(){this.header=w.create("div",{className:f+"header"});this.container.appendChild(this.header);this.titleElement=w.create("h2",{parent:this.header});var O=this.title||this._getDefaultTitle();this.titleElement.innerHTML=w.trim(O);return this.header},draw5minElements:function(){this.fiveMinElements=w.create("div",{className:f+"5min-elements"});if(this.serverData.by5minLink){var O=w.create("a",{className:f+"by-5min-link",innerHTML:"By 5min"});O.setAttribute("title","www.5min.com");O.setAttribute("href","http://www.5min.com");O.setAttribute("target","_blank");G.addRule("#"+this.innerWrapper.id+" A."+O.className,"color: "+this.headerTextColor+" !important");this.fiveMinElements.appendChild(O)}else{if(this.serverData.by5minText){var P=w.create("span",{className:f+"by-5min-text",innerHTML:"By 5min"});G.addRule("#"+this.innerWrapper.id+" SPAN."+P.className,"color: "+this.headerTextColor+" !important");this.fiveMinElements.appendChild(P)}}return this.fiveMinElements},drawVideos:function(P){if(g){w.log("drawVideos "+this.videos)}if(!this.videos){return}w.css(this.container,{visibility:"hidden",marginLeft:"-8000px",position:"absolute",top:0,left:0,width:P.tsWidth+"px",fontSize:"11px"});document.body.appendChild(this.container);G.addRule("#"+this.innerWrapper.id+" DIV."+f+"desc A","color: "+this.textFGColor+" !important");G.addRule("#"+this.innerWrapper.id+" LI."+f+"ts-"+this.thumbnailSize+"-hover DIV."+f+"desc A","color: "+this.textFGColor_MO+" !important");P.carouselColCount=0;P.numOfVideosLoaded=0;this.videoObjects=[];var U=0;do{var W=w.create("li",{className:f+"video-col"});this.videosList.appendChild(W);P.carouselColCount++;var V=0;var Z=w.create("ul");W.appendChild(Z);for(var aa=0;aa<P.videoRowCount;aa++){var O=w.create("li",{className:f+"video-row clearfix"});w.css(O,{width:P.carouselColWidth+"px"});Z.appendChild(O);var T=w.create("ul");O.appendChild(T);for(var R=0;R<P.videoColCount;R++){if(U==this.videos.length||V==P.numOfThumbs){break}if(this.ad&&this.adUnitLocation==2&&!this.ad.wasInserted&&U==3&&aa==0){var Q=w.create("li");w.addCls(Q,f+"vi");w.addCls(Q,f+"last");T.appendChild(Q);Q.appendChild(this.ad);w.css(Q,{"float":"right"});w.css(Q.previousSibling,{marginRight:0});this.ad.wasInserted=true}else{var X=this.ht?this.ht:J;X=this.convertEnum(X,"ht");var Y=new z();var S=Y.init({showLightBoxFunc:this.showVideo,dimensionSettings:P,imageSource:this.videos[U].ThumbURL,imageDimensions:P.initialVideoSize,htTarget:X,title:this.videos[U].Title,directURL:this.getDirectURL(),PageURL:this.videos[U].PageURL,EmbededURL:this.videos[U].EmbededURL,ReferrerURL:this.videos[U].ReferrerURL,text:this.videos[U].Title,playButtonImg:this.playButtonImg,playButtonImg_MO:this.playButtonImg_MO,playButtonLocation:this.playButtonLocation?this.playButtonLocation:this.serverData.playButtonLocation,videoSize:this._getItemRelevantSize(),textFGColor:this.textFGColor,textFGColor_MO:this.textFGColor_MO,textBGColor:this.textBGColor,textBGColor_MO:this.textBGColor_MO,textFont:this.thumbnailTitleFont,thumbnailSize:this.thumbnailSize,id:this.videos[U].ID,showClickButton:this.showClickButton?this.showClickButton:this.serverData.showClickToPlay});this.videoObjects.push(Y);if(R==P.videoColCount-1){Y.makeLast();if(this.textLocation==1){w.css(S,{marginLeft:P.addToLast+"px"})}else{w.css(S,{width:"auto"});w.css(S.textDiv,{paddingRight:P.addToLast+"px"})}}T.appendChild(S);Y.ellipsisizeText(P);if(P.carouselColCount==1){Y.load();P.numOfVideosLoaded++}U++;V++}}if(U==this.videos.length){break}}}while(U<this.videos.length);w.css(this.container,{visibility:"",marginLeft:"",position:"",top:"",left:""});w.prepend(this.innerWrapper,this.container);setTimeout(w.bind(function(){w.css(this.container,{zoom:1})},this),12);w.removeCls(this.container,f+"loading")},getDirectURL:function(){var O=undefined;if(this.directURL){O=this.directURL}else{if(this.directUrl){O=this.directUrl;this.directURL=this.directUrl}}return O},drawAd:function(){if(this.adUnit!=true&&this.adUnit!="true"){return false}if(this.serverData.adUnitURL==undefined){return false}this.ad=w.create("iframe",{className:f+"ad",styles:{visibility:"hidden"}});this.ad.setAttribute("frameborder",0);this.ad.setAttribute("scrolling","no");this.ad.src=this.serverData.adUnitURL;w.css(this.ad,{width:this.adUnitWidth+"px",height:this.adUnitHeight+"px"});if(this.adUnitLocation==0){w.addCls(this.innerWrapper,f+"side-addUnit")}if(this.adUnitLocation==2){this.ad.wasInserted=false}else{this.innerWrapper.appendChild(this.ad)}},setAdUnitLocation:function(){if(this.adUnitWidth==160){this.adUnitLocation=0}else{if(this.adUnitWidth==125){this.adUnitLocation=2}else{this.adUnitLocation=1}}},drawCarouselNav:function(R){var U=w.create("div",{className:f+"carousel-nav"});var V=R.firstChild;R.insertBefore(U,V);if(w.browser.engine=="webkit"){w.css(R,{width:"92px"})}var T=w.create("a",{className:f+"carousel-previous",parent:U,innerHTML:"&lsaquo;"});G.addRule("#"+this.innerWrapper.id+" A."+T.className,"color: "+this.headerTextColor+" !important");var Q=w.create("span",{parent:U,innerHTML:"..."});G.addRule("#"+this.innerWrapper.id+" ."+U.className+" SPAN","color: "+this.headerTextColor+" !important");var P=w.create("a",{className:f+"carousel-next",parent:U,innerHTML:"&rsaquo;"});G.addRule("#"+this.innerWrapper.id+" A."+P.className,"color: "+this.headerTextColor+" !important");if(this.serverData.prevImg&&this.serverData.nextImg){T.innerHTML=P.innerHTML="";w.css(Q,{display:"none"});var S=new Image();S.src=this.serverData.prevImg;G.addRule("#"+this.innerWrapper.id+" A."+T.className,"width: 30px; height: 30px; background: url("+this.serverData.prevImg+") left 2px no-repeat; margin-top: -9px;");if(this.serverData.prevImg_MO){G.addRule("#"+this.innerWrapper.id+" A."+T.className+"-hover","background-image: url("+this.serverData.prevImg_MO+");");var W=new Image();W.src=this.serverData.prevImg_MO}if(this.serverData.prevImg_Disable){G.addRule("#"+this.innerWrapper.id+" A."+T.className+"-disabled","background-image: url("+this.serverData.prevImg_Disable+"); padding: 0 !important; left: 0 !important;");var W=new Image();W.src=this.serverData.prevImg_Disable}else{G.addRule("#"+this.innerWrapper.id+" A."+T.className+"-disabled","padding: 0 !important; left: 0 !important;")}G.addRule("#"+this.innerWrapper.id+" A."+P.className,"width: 30px; height: 30px; background: url("+this.serverData.nextImg+") left 2px no-repeat; margin-top: -9px;");var O=new Image();O.src=this.serverData.nextImg;if(this.serverData.nextImg_MO){G.addRule("#"+this.innerWrapper.id+" A."+P.className+"-hover","background-image: url("+this.serverData.nextImg_MO+");");var W=new Image();W.src=this.serverData.nextImg_MO}if(this.serverData.nextImg_Disable){G.addRule("#"+this.innerWrapper.id+" A."+P.className+"-disabled","background-image: url("+this.serverData.nextImg_Disable+"); padding: 0 !important; left: 0 !important;");var W=new Image();W.src=this.serverData.nextImg_Disable}else{G.addRule("#"+this.innerWrapper.id+" A."+P.className+"-disabled"," padding: 0 !important; left: 0 !important;")}}return{previousButton:T,nextButton:P}},drawFooter:function(){this.footer=w.create("div",{className:f+"footer clearfix",parent:this.container});w.css(this.footer,{borderTopColor:this.headerTextColor});return this.footer},showVideo:function(O){b.show(O)},setTextLocation:function(O){w.addCls(this.container,f+"tl-"+O)},setHeader:function(S,Q,T){w.css(this.header,{color:S});var R="color: "+this.headerTextColor+" !important;";var O="#"+this.innerWrapper.id+" #"+this.container.id+" ."+this.header.className;w.css(this.titleElement,{color:S});G.addRule(O+" .fmts-by-5min-text, "+O+" .fmts-by-5min-link",R);if(Q){Q=Q.split("|");var P=Q[1]=="11px"?"13px":"normal";w.css(this.titleElement,{fontFamily:Q[0],fontSize:Q[1],fontWeight:Q[2],lineHeight:P});R=R+"font-family: "+Q[0]+"!important; font-size: "+Q[1]+"!important; font-weight: "+Q[2]+"!important; line-height: "+P}G.addRule(O+" H2",R);w.css(this.header,{borderBottomColor:T})},setTitle:function(O){if(w.trim(O)){this.title=O}if(this.titleElement){this.titleElement.innerHTML=this.title||this._getDefaultTitle()}},_getDefaultTitle:function(){return"Related Videos"}});function z(){var aA,ag,ay,ai,T,ap,V,aw,ah,ad,az,ao,ak,S,aj,Z,Y,ae,ar,al,au,af,R,at=false;var aq,Q,X,ab,U,aa,O,ac;var W=function(aD,aG,aH,aF,aE){ap=w.create("a");if(aD){ap.setAttribute("href",aD);if(aH){ap.setAttribute("target",aH)}if(aF){ap.setAttribute("title",aF)}}V=w.create("img",{parent:ap});V.setAttribute("width",aE.width);V.setAttribute("height",aE.height);if(aF){V.setAttribute("alt",aF)}w.addEvent(V,"load",an);aw=aG};var ax=function(aD,aG,aI,aF,aH,aE){ah=w.create("a",{className:f+"btn_play",innerHTML:"Play"});ak=w.create("a",{className:f+"btn_click",innerHTML:"Click to Play"});if(aH==false){w.css(ak,{display:"none"})}if(aD){ah.setAttribute("href",aD);ak.setAttribute("href",aD);if(aI){ah.setAttribute("target",aI);ak.setAttribute("target",aI)}if(aF){ah.setAttribute("title",aF);ak.setAttribute("title",aF)}}if(aG){w.css(ah,{backgroundImage:"url("+aG+")"});if(w.browser.engine=="ie"){w.css(ah,{filter:"progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+aG+"');"})}}switch(aE){case 1:w.css(ah,{bottom:5,right:5,left:"auto",top:"auto"});break;case 2:w.css(ah,{bottom:5,left:22,top:"auto"});break;case 3:w.css(ah,{top:19,right:5,left:"auto"});break;case 4:w.css(ah,{top:19,left:22});break;case 0:default:break}if(w.browser.engine=="ie"){}};var am=function(aJ,aK,aE,aI,aH,aD,aF){aH=aH;Y=w.create("div",{className:f+"desc"});ae=w.create("a",{innerHTML:aH,parent:Y});if(aK){ae.setAttribute("href",aK);if(aI){ae.setAttribute("target",aI);ae.setAttribute("title",aH)}}if(aF){aF=aF.split("|");var aG=aF[1]=="11px"?"13px":"normal";w.css(Y,{fontFamily:aF[0],fontSize:aF[1],fontWeight:aF[2],lineHeight:aG});w.css(ae,{fontFamily:aF[0],fontSize:aF[1],fontWeight:aF[2],lineHeight:aG});G.addRule("#"+m+" ."+f+"desc a","font-family:"+aF[0]+"!important; font-size:"+aF[1]+"!important; font-weight:"+aF[2]+"!important; line-height: "+aG)}};var an=function(){w.removeCls(aA,Q);w.removeCls(aA,aa);w.addCls(aA,X);at=true};var aB=function(){w.addCls(aA,O);w.css(aA,{backgroundColor:al});if(az){w.css(ah,{backgroundImage:"url("+az+")"});if(w.browser.engine=="ie"){w.css(ah,{filter:"progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+az+"');"})}}};var av=function(){w.removeCls(aA,O);w.css(aA,{backgroundColor:ar});if(az){w.css(ah,{backgroundImage:"url("+ad+")"});if(w.browser.engine=="ie"){w.css(ah,{filter:"progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+ad+"');"})}}};var P=function(aD){w.stopEvent(aD);if(typeof b!="undefined"){ag({EmbededURL:ai,title:aj,PageURL:ay,ReferrerURL:T})}else{window.open(ay,"5minwindow")}};var aC=function(aD,aE){if(aD.indexOf("http://")==-1&&aD.indexOf("https://")==-1){aD="http://"+aD}aD=aD.replace("[VIDEOID]",aE);return aD};return{init:function(aE){aq=f+"vi";Q=aq+"-loading";X=aq+"-loaded";ab=aq+"-notloaded";U=f+"ts-"+aE.thumbnailSize;aa=U+"-loading";O=U+"-hover";ac=f+"last";ar=aE.textBGColor;al=aE.textBGColor_MO;au=aE.textFGColor;af=aE.textFGColor_MO;R=aE.textFont;ag=aE.showLightBoxFunc;ai=aE.EmbededURL;aj=aE.text;ay=aE.PageURL;T=aE.ReferrerURL;Z=(typeof aE.directURL=="undefined")?null:aC(aE.directURL,aE.id);S=(typeof aE.directURL=="undefined")?"":S;ad=aE.playButtonImg;az=aE.playButtonImg_MO;W(Z,aE.imageSource,aE.htTarget,S,aE.imageDimensions);ax(Z,ad,aE.htTarget,S,aE.showClickButton,aE.playButtonLocation);am(S,Z,aE.textFGColor,aE.htTarget,aE.text,aE.imageDimensions,R);aA=w.create("li",{className:aq+" "+U+" "+ab,children:[w.create("div",{className:f+"img_wrapper",children:[w.create("div",{className:f+"img",children:[ap]}),w.create("div",{className:f+"play",children:[ah,ak]})]}),Y],styles:{backgroundColor:aE.textBGColor}});w.addEvent(aA,"mouseover",aB);w.addEvent(aA,"mouseout",av);if(typeof aE.directURL=="undefined"){w.addEvent(aA,"click",P)}if(typeof aE.dimensionSettings.textWidth!="undefined"){var aD=aE.videoSize.width+aE.dimensionSettings.textWidth;w.css(aA,{width:aD+"px",marginRight:aE.dimensionSettings.spaceWidth+"px",marginLeft:0});w.css(Y,{width:aE.dimensionSettings.textWidth+"px"});w.css(Y,{height:aE.videoSize.height+"px"})}else{var aD=aE.videoSize.width;w.css(aA,{width:aD+"px",marginRight:aE.dimensionSettings.spaceWidth+"px",marginLeft:0});w.css(Y,{height:aE.videoSize.textHeight+"px"})}aA.textDiv=Y;aA.textLink=ae;return aA},load:function(){if(!at){w.removeCls(aA,ab);w.addCls(aA,Q);w.addCls(aA,aa);V.src=aw}},ellipsisizeText:function(aE){var aH=parseInt(Y.style.height,10);var aK=document.body;var aF;var aI=ae.textContent;if(aI!==undefined){aF="textContent"}else{aI=ae.innerText;if(aI!==undefined){aF="innerText"}else{aI=ae.innerHTML;aF="innerHTML"}}ae.title=aI;var aG=aI.split(/\s+/g);var aD=aG.length;var aJ=[];while(ae.offsetHeight>aH&&aD>0){aJ=aG.slice(0,--aD);ae[aF]=aJ.join(" ")+"...";if(!aA.title){aA.title=aI}}w.css(ae,{height:aH+"px"})},makeLast:function(){w.addCls(aA,ac)},destroy:function(){w.removeEvent(aA,"mouseover",aB);w.removeEvent(aA,"mouseout",av);w.removeEvent(aA,"click",P);w.removeEvent(V,"load",an)}}}y.prototype.Load=y.prototype.load;var a=f+"lb-";var I=f+"lb-cn-";var K=470,q=500;var j=30;function p(){}w.extend(p.prototype,{init:function(S,Q){this.data=S;var O="FIVEMIN-"+parseInt(Math.random(10000)*10000);var P=I+"cb-ad-"+O+"-";var R=S.lightboxAnim;this.box.init({animConfig:{duration:300,type:R,onHideStart:w.bind(function(){this.player.hide()},this),onHideComplete:w.bind(function(){this.overlay.hide()},this),onShowComplete:w.bind(function(){},this)},hideFunc:w.bind(function(){this.hide()},this),show5minLink:S.show5minLink,show5minText:S.show5minText,adIdPrefix:P});this.overlay.init({opacity:S.overlayOpacity,bgColor:S.overlayColor,animConfig:{duration:300,onShowComplete:function(){w.restoreDocument()}},onClickFunc:w.bind(function(){this.hide()},this)});this.player.init({adIdPrefix:P,instanceNumber:Q});this.box.appendToLeftContent(this.player.getElement());this.sharing.init();this.box.appendToRightContent(this.sharing.getElement());w.addEvent(document,"keydown",w.bind(function(T){this.hideOnEsc(T)},this));w.addEvent(w.document,"keydown",w.bind(function(T){this.hideOnEsc(T)},this))},setTitle:function(O){this.box.setTitle(O)},updateSharingLinks:function(P,O){this.sharing.update({title:P,PageURL:O})},showBottomAd:function(){this.box.showBottomAd()},box:function(){var O,V,Q,R,T,P,S,U=false;return{init:function(Y){V=Y.animConfig;if(V.type==2||V.type==3){this.boxShadow.init()}var W=w.docSize(y.getTopMostWindow().document);O=w.create("div",{id:I+"wrapper",className:I+"wrapper",parent:y.getTopMostWindow().document.body});T=w.create("iframe",{parent:y.getTopMostWindow().document.body,id:I+"iframe",name:I+"iframe",src:"javascript:void(0);",frameborder:0,scrolling:"no",styles:{position:"fixed",top:"-20px",left:"-20px",filter:"progid:DXImageTransform.Microsoft.Alpha(style=0,opacity=0)",opacity:0,width:"100%",height:W.height+"px",zIndex:1,visibility:"",display:"none"}});w.create("div",{className:a+"top",parent:O});R=w.create("div",{className:a+"cn",parent:O});titleWrapper=w.create("div",{className:a+"title-wrapper",parent:R});Q=w.create("div",{className:I+"title",parent:titleWrapper});w.create("div",{className:I+"close",innerHTML:"X",parent:titleWrapper,events:{click:Y.hideFunc}});if(Y.show5minLink){var X=w.create("a",{className:I+"by-5min-link",innerHTML:"by 5min",parent:titleWrapper});X.setAttribute("href","http://www.5min.com");X.setAttribute("target","http://www.5min.com")}else{if(Y.show5minText){w.create("span",{className:I+"by-5min-text",innerHTML:"by 5min",parent:titleWrapper})}}var Z=w.create("div",{className:"clearfix",parent:R});P=w.create("div",{className:I+"left-cn",parent:Z});S=w.create("div",{className:I+"right-cn",parent:Z});w.create("div",{id:Y.adIdPrefix+"side-top",className:I+"ad-side-top",parent:S});w.create("div",{id:Y.adIdPrefix+"side-bottom",className:I+"ad-side-bottom",parent:S});this.bottom_ad_wrapper=w.create("div",{className:I+"ad-bottom",parent:O});w.create("div",{className:I+"ad-bottom-up",parent:this.bottom_ad_wrapper});w.create("div",{id:Y.adIdPrefix+"bottom",className:I+"ad-bottom-down",parent:this.bottom_ad_wrapper});w.create("div",{className:a+"bottom",parent:O})},show:function(W){w.css(T,{display:""});w.css(O,{top:this._getTopPos()+"px"});this.setTitle(W.title);switch(V.type){case 1:w.css(O,{opacity:0,display:"block"});new w.fx(O,{duration:V.duration,onComplete:function(){if(V.onShowComplete){V.onShowComplete()}if(W.onShowComplete){W.onShowComplete();U=true}}}).start({opacity:1});break;case 2:var X=this.boxShadow.getElement();w.css(X,{width:0,height:0,marginLeft:0,top:this._getTopPos()+360,display:"block",opacity:0});new w.fx(X,{duration:200,onComplete:function(){w.css(X,{display:"none"});w.css(O,{display:"block"});if(V.onShowComplete){V.onShowComplete()}if(W.onShowComplete){W.onShowComplete();U=true}}}).start({width:813,height:630,marginLeft:-406,top:this._getTopPos()+7,opacity:0.7});break;case 3:var X=this.boxShadow.getElement();w.css(X,{width:740,height:560,marginLeft:-370,top:this._getTopPos()+35,display:"block",opacity:0});new w.fx(X,{duration:400,onComplete:function(){w.css(X,{display:"none"});w.css(O,{display:"block"});if(V.onShowComplete){V.onShowComplete()}if(W.onShowComplete){W.onShowComplete();U=true}}}).start({width:813,height:630,marginLeft:-406,top:this._getTopPos()+7,opacity:0.85});break;case 0:default:w.css(O,{display:"block"});if(V.onShowComplete){V.onShowComplete()}if(W.onShowComplete){W.onShowComplete();U=true}}},hide:function(){if(!U){return}w.css(T,{display:"none"});if(V.onHideStart){V.onHideStart()}switch(V.type){case 1:new w.fx(O,{onComplete:w.bind(function(){w.css(O,{display:"none"});if(V.onHideComplete){V.onHideComplete()}},this),duration:V.duration}).start({opacity:0});break;case 2:var W=this.boxShadow.getElement();w.css(O,{display:"none"});w.css(W,{display:"block",top:this._getTopPos()+7});new w.fx(W,{duration:200,onComplete:function(){if(V.onHideComplete){V.onHideComplete()}}}).start({width:0,height:0,marginLeft:0,top:this._getTopPos()+360,opacity:0});break;case 3:var W=this.boxShadow.getElement();w.css(W,{width:813,height:630,marginLeft:-406,top:this._getTopPos()+7,opacity:0.85,display:"block"});w.css(O,{display:"none"});new w.fx(W,{duration:400,onComplete:function(){if(V.onHideComplete){V.onHideComplete()}}}).start({width:740,height:560,marginLeft:-370,top:this._getTopPos()+35,opacity:0});break;case 0:default:w.css(O,{display:"none"});if(V.onHideComplete){V.onHideComplete()}}U=false;w.css(this.bottom_ad_wrapper,{display:"none"})},setTitle:function(W){Q.innerHTML=W},showBottomAd:function(){w.css(this.bottom_ad_wrapper,{display:"block"})},appendToRightContent:function(W){S.appendChild(W)},appendToLeftContent:function(W){P.appendChild(W)},getElement:function(){return O},_getTopPos:function(){var W=y.getTopMostWindow().document;var X=function(){if(typeof pageYOffset!="undefined"){return pageYOffset}else{var Z=W.body;var Y=W.documentElement;Y=(Y.clientHeight)?Y:Z;return Y.scrollTop}}();X+=j;return X},boxShadow:function(){var W;return{init:function(){W=w.create("div",{id:I+"shadow",className:I+"shadow",parent:y.getTopMostWindow().document.body})},getElement:function(){return W}}}()}}(),overlay:function(){var P,O,Q;var R=function(){if(w.browser.engine=="ie"&&w.browser.version<8){var S=w.docSize(y.getTopMostWindow().document);w.css(P,{height:S.height+"px",width:S.width+"px"})}};return{init:function(T){Q=T.animConfig;O=T.opacity;var S=w.create("div",{className:f+"quirksmode "+f+w.browser.engine,parent:y.getTopMostWindow().document.body});P=w.create("div",{id:a+"overlay",className:D+" "+a+"overlay",parent:S,styles:{backgroundColor:T.bgColor}});w.addEvent(P,"click",T.onClickFunc)},show:function(S){R();w.css(P,{opacity:0,display:"block"});new w.fx(P,{onComplete:w.bind(function(){if(Q.onShowComplete){Q.onShowComplete()}if(S.onShowComplete){S.onShowComplete()}},this),duration:Q.duration}).start({opacity:O})},hide:function(){new w.fx(P,{onComplete:w.bind(function(){w.css(P,{display:"none"})},this),duration:Q.duration}).start({opacity:0})}}}(),player:function(){var R,P,Q,O=["side-top","side-bottom","bottom"];return{init:function(S){R=w.create("div",{className:I+"player-container"});P=S.adIdPrefix;Q=S.instanceNumber},update:function(S){R.innerHTML=this.getHtml(S)},show:function(){w.css(R,{display:"block"})},hide:function(){w.css(R,{display:"none"});R.innerHTML="";this.hideAds()},getHtml:function(S){S=S.replace(/cbHtmlID=.*?(?:&|$)/i,"");S+="&relatedMode=3";var T=M(this._getFlashAdParams());S+="&"+T;S+="&playlistUrl=javascript(ThumbSeed._instances["+Q+"].getPlayListURL)";S+="&relatedOnVideoChanged=ThumbSeed._instances["+Q+"].onRelatedVideoChanged";var U;var W=S.split("?");var V=W[0];var X=W[1];if(w.browser.engine=="ie"){U='<object id="FiveminPlayer" width="'+K+'" height="'+q+' "classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000"><param name="allowfullscreen" value="true"><param name="allowScriptAccess" value="always"><param name="movie" value="'+V+'"><param name="flashvars" value="'+X+'"><param name="wmode" value="opaque"></object>'}else{U='<embed name="FiveminPlayer" src="'+V+'" flashvars="'+X+'" type="application/x-shockwave-flash" width="'+K+'" height="'+q+'" allowfullscreen="true" allowScriptAccess="always" wmode="opaque"></embed>'}return U},_getFlashAdParams:function(){var S={cbHtmlID:this._getAdElementId(O[0]),cbWidth:300,cbHeight:250,cbHtmlID1:this._getAdElementId(O[1]),cbWidth1:300,cbHeight1:60,cbHtmlID2:this._getAdElementId(O[2]),cbWidth2:728,cbHeight2:90};w.extend(S,{cbIsFairBalance1:true,cbFailoverUrl2:"fwscript"});return S},_getAdElementId:function(S){return P+S},hideAds:function(){for(var S=0;S<O.length;S++){var T=document.getElementById(this._getAdElementId(O[S]));T.innerHTML=""}},getElement:function(){return R}}}(),sharing:function(){var Q,O=[{type:"twitter",text:"Twitter"},{type:"facebook",text:"Facebook"},{type:"myspace",text:"Myspace"},{type:"digg",text:"Digg"},{type:"wordpress",text:"WordPress"},{type:"stumbleupon",text:"Stumbleupon"}],R=[],P="http://www.addthis.com/bookmark.php?v=250&source=tbx-250&t=0&lng=he";return{init:function(){Q=w.create("div",{className:a+"sharing"});w.create("div",{className:a+"sharing-title",innerHTML:"Share this video",parent:Q});w.create("div",{className:a+"sharing-hr",parent:Q});var T=w.create("div",{className:a+"sharing-list clearfix",parent:Q});for(var S=0;S<O.length;S++){var U=w.create("a",{className:"btn_share_"+O[S].type,innerHTML:"<em class='"+a+"sharing-icon'></em>"+O[S].text,parent:T});U.setAttribute("href","javascript:void(0);");R.push(U)}},update:function(U){var T=U.ReferrerURL||U.PageURL;for(var S=0;S<R.length;S++){R[S].href=this.getURL(O[S].type,T,U.title);R[S].setAttribute("target","_blank")}},getURL:function(S,V,U){U=U.replace("'","&#39;");var T=P;T+="&s="+S;T+="&url="+V;T+="&title="+U;return T},getElement:function(){return Q}}}(),show:function(P){w.setDocument(y.getTopMostWindow().document);var O=this;this.overlay.show({onShowComplete:w.bind(function(){this.box.show({title:P.title,onShowComplete:function(){O.player.update(P.EmbededURL);O.player.show();O.sharing.update(P)}})},this)})},hideOnEsc:function(O){var P=(window.event)?window.event.keyCode:O.keyCode;if(P==27){this.hide()}},hide:function(){this.box.hide()}});function c(){if(!c._overwritten){c._overwritten=true;var O=v(location.search.substr(1));c=function(P,Q){P=P.toLowerCase();return(O[P]===undefined?Q:O[P])||""};return c.apply(null,arguments)}}function v(O){var P={};O.replace(/(.*?)=(.*?)(?:&|$)/g,function(R,Q,S){P[Q]=decodeURIComponent(S)});return P}function l(P,O,Q){Q=w.extend({preventCache:true},Q||{});y.jsonpCallbacks.push(O);P+=(P.indexOf("?")>-1?"&":"?")+"callback=FIVEMIN.ThumbSeed.jsonpCallbacks["+(y.jsonpCallbacks.length-1)+"]";if(Q.preventCache){P+="&rnd="+w.time()}if(g){w.log("[json:] ",P)}var R=w.create("script",{src:P,type:"text/javascript",parent:t()})}function M(Q){var P=[];w.each(Q,function(S,R){P.push(R+"="+encodeURIComponent(S))});var O=P.join("&");return O}y.jsonpCallbacks=[];var E={sid:Number,url:String,categories:String,layout:String,headerColor:String,backgroundColor:String,displayHeader:Boolean,displayBorder:Boolean,displayFooter:Boolean,playList:String,fallback:String,fallbackType:String,featured:Boolean,contentQuality:Number,videoCount:Number,layout:String,testData:String,autoStart:Boolean,libraryID:Number};y.loadParameterizedScripts=function(O){var P=w.getElements("script"),Q=[];w.each(P,function(U){if(U.getAttribute("readByThumbSeed")=="true"){return}else{U.setAttribute("readByThumbSeed","true")}if(A.test(U.src)){if(g){w.log("ThumbSeed Creation #"+O);w.addDomReady(function(){w.log("DOM ready")})}var V=U.src.split("?")[1];if(V.indexOf("sid=")==-1){return}if(V){V=v(V);V=w.map(V,function(X,Y){var W=E[Y];if(W==Boolean){return X=="true"}return W?W(X):X})}if(g){w.log(V)}var S;var R=w.getById(V.wrapperToShow);if(V.wrapperToShow){if(g){w.log("Client sent a wrapperToShow ("+V.wrapperToShow+")")}}if(g){w.log("wrapperToShow not found")}if(g){w.log("Creating DIV as wrapper")}S=w.create("div");U.parentNode.insertBefore(S,U);var T=new y(S,U);if(V){w.extend(T,V)}T.load()}})};function u(){var O,Q,S,ae,ab,T,ac,W=0,Z,aa,R,Y;var ad=function(){af()};var P=function(){var ah=w.currCss(O,"left");ah=parseInt(ah,10);return ah};var af=function(){if(W==(Z-1)){Q.disable()}else{Q.enable()}if(W==0){S.disable()}else{S.enable()}};var ag=function(){Q.disable(false);S.disable(false)};function X(){var ah=this,ak,al,aj,ai;return{init:function(am){ak=am.element;ak.setAttribute("href","");aj=am.onclickFunc;al=ak.className;w.addEvent(ak,"click",this.onClick);w.addEvent(ak,"mouseover",this.onMouseOver);w.addEvent(ak,"mouseout",this.onMouseOut)},disable:function(am){if(am!=false){w.addCls(ak,f+"button-disabled");w.addCls(ak,al+"-disabled")}ai=true},enable:function(am){if(am!=false){w.removeCls(ak,f+"button-disabled");w.removeCls(ak,al+"-disabled")}ai=false},onClick:function(am){if(typeof am!="undefined"&&am.type=="click"){w.stopEvent(am)}if(!ai){aj.call()}},onMouseOver:function(am){w.addCls(ak,f+"button-hover");w.addCls(ak,al+"-hover")},onMouseOut:function(am){w.removeCls(ak,f+"button-hover");w.removeCls(ak,al+"-hover")},getParent:function(){return ak.parentNode},destroy:function(){w.removeEvent(ak,"click",this.onClick);w.removeEvent(ak,"mouseover",this.onMouseOver);w.removeEvent(ak,"mouseout",this.onMouseOut)}}}var U=function(ah){var ai=(window.event)?window.event.keyCode:ah.keyCode;if(ai==39){Q.onClick()}else{if(ai==37){S.onClick()}}};var V=function(){var ai=W*R-(R-Y);var aj=ai+R;for(var ah=ai;ah<aj&&ah<aa.length;ah++){aa[ah].load()}};return{init:function(ah){O=ah.listEl;T=parseInt(ah.moveBy,10);Z=ah.itemCount;R=ah.videosInColCount;Y=ah.numOfVideosLoaded;aa=ah.videos;w.css(ah.parent,{height:ah.listHeight+"px"});w.css(O,{position:"absolute",left:0});var ai={element:O,styleAttribute:"left",onComplete:ad};if(ah.duration){ai.duration=ah.duration}ac=new o(ai);Q=new X();Q.init({element:ah.nextButton,onclickFunc:this.next});S=new X();S.init({element:ah.previousButton,onclickFunc:this.previous});w.addEvent(document,"keyup",U);af()},next:function(){ag();var ah=parseInt(P(),10);ac.updateParams({from:ah,to:ah-T});ac.animate();W++;V()},previous:function(){ag();var ah=parseInt(P(),10);ac.updateParams({from:ah,to:ah+T});ac.animate();W--},destroy:function(){var ah=Q.getParent();Q.destroy();Q=null;S.destroy();S=null;w.removeEvent(document,"keyup",U);var ah=w.getElement(".fmts-carousel-nav");ah.innerHTML=""}}}function o(R){var T=0;var Q=(R.to-R.from);var W=R.onComplete;var U=[1,2,3,4,5,6,7,8,9,10,9,8,7,6,5,4,3,2,1];var P=U.length;var S=[];var O=R.from;var V=(R.duration)?(R.duration/P):20;var X;this.updateParams=function(aa){Q=(aa.to-aa.from);O=aa.from;for(var Z=0;Z<P;Z++){O+=(Q*U[Z]/100);O=Math.floor(O*1000)/1000;S[Z]=O}};this.animate=function(){setTimeout(Y,V)};var Y=function(){var Z=S[T];R.element.style.left=Z+"px";T++;if(T<S.length){setTimeout(Y,V)}else{if(W){W.call()}T=0}}}return y}()}var ThumbSeed=FIVEMIN.ThumbSeed;if(typeof thumbseedScriptCallCount=="undefined"){thumbseedScriptCallCount=-1}thumbseedScriptCallCount++;ThumbSeed.loadParameterizedScripts(thumbseedScriptCallCount);