function searchTabIndex(a){switch(a){case"articles":return 2;case"products":return 0;case"downloads":return 3;default:return 0}}function setMoreLink(e,c,d,a,g){if(c.paid){var f={keyword:"companyid:"+a,override:'"'+g+'"',searchType:searchTabIndex(d)};var h=c.searchUrl.indexOf("?")>=0?"&":"?";var b=c.searchUrl+h+$.param(f);e.attr("href",b);return}switch(d.toLowerCase()){case"articles":e.attr("href",c.newsPage);break;case"products":e.attr("href","/content/productshowcase/");break;case"downloads":e.attr("href",c.downloadLibrary);break;default:e.attr("href",c.newsPage);break}}function retrieveList(c,d,a,e,b){$.getJSON(c.thisCompanyUrl,{companyId:a,documentType:d,currentDocument:b},function(f){$(".mostpopularcontent").find("li").remove();setMoreLink($(".navmore > a"),c,d,a,e);$.each(f,function(h,j){var g=$("<li/>").append($("<a/>").html(j.Title).attr("href",j.LinkUrl));$(".mostpopularcontent").append(g)})})}$(document).ready(function(){$(".tabular table[border!=0]").each(function(){if($(this).attr("border")){$(this).css("border","outset "+$(this).attr("border")+"px")}});$(".tabular td").each(function(){var a=$(this).parent().parent().parent();if($(a).attr("cellpadding")&&$(a).attr("cellpadding")!="0"){$(this).css("padding",$(a).attr("cellpadding")+"px")}});if($.browser.msie){$(".tabular table").each(function(){if($(this).css("padding")){$(this).css("margin",$(this).css("padding")+"px")}})}if($("#companySpecific").length>0){this.rules={leadType:"required",specIndustry:"required",specProduct:"required",specProject:"required",specTimeFrame:"required"};this.messages={leadType:"Please choose one of the options.",specIndustry:"Please choose an industry.",specProduct:"Please choose a equipment/service.",specProject:"Please choose stage of your project.",specTimeFrame:"Please choose a project timeframe."}}else{this.rules={leadType:"required"};this.messages={leadType:"Please choose one of the options."}}if($("#leadTypeSelection").length>0||$("#companySpecific").length>0){$("#dlForm").validate({rules:this.rules,messages:this.messages,errorLabelContainer:"#errorList > ul",errorElement:"span",wrapper:"li",errorClass:"field-validation-error",highlight:function(a){$(a).addClass("input-validation-error")},unhighlight:function(a){$(a).removeClass("input-validation-error")}})}});function setUpFlowPlayer(b,d,a,c,e){$f(b,"../Content/flash/flowplayer-3.1.5.swf",{clip:{url:d,scaling:"orig",autoPlay:false,autoBuffering:(a=="Audio"?false:true),fadeInSpeed:20000,onStart:function(f){vertTracker.push(["_trackEvent",a,"Play",f.url]);this.getScreen().css({opacity:1})},onPause:function(f){vertTracker.push(["_trackEvent",a,"Pause",f.url,parseInt(this.getTime())])},onResume:function(f){vertTracker.push(["_trackEvent",a,"Resume",f.url])},onStop:function(f){vertTracker.push(["_trackEvent",a,"Stop",f.url])},onFinish:function(f){vertTracker.push(["_trackEvent",a,"Finish",f.url])},onLastSecond:function(){this.getScreen().animate({opacity:0},3000)}},plugins:{audio:{url:"../Content/flash/plugins/flowplayer.audio-3.1.2.swf"},controls:{fullscreen:(a=="Audio"?false:true),height:30}},key:(c==undefined?"#@1cdee5289dd365a55fe":c),logo:{fullscreenOnly:false,zIndex:0,top:"45%",left:"50%",url:"http://"+location.host+"/sites/images/"+(e==undefined?"vertmarkets":e)+"/video_logo_large.png"}})};