// JavaScript Document function MM_swapImgRestore() { //v3.0 var i,x,a=document.MM_sr; for(i=0;a&&i0&&parent.frames.length) { d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);} if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i -1) || (location.href.toLowerCase() == "http://www.tvland.com/") || (location.href.toLowerCase() == "http://www.tvland.com/index.jhtml")) { //viewPercent = 0; popuplink = "http://surveys.relevantview.com/aslukadooesesuj.asp?q50=1"; posTop = 425; } if (location.href.indexOf("/schedule/") > -1) { //viewPercent = 2; popuplink = "http://surveys.relevantview.com/aslukadooesesuj.asp?q50=3"; } if (location.href.indexOf("/community/") > -1) { //viewPercent = 0; popuplink = "http://surveys.relevantview.com/aslukadooesesuj.asp?q50=2"; } if (location.href.indexOf("/prime/") > -1) { //viewPercent = 0; popuplink = "http://surveys.relevantview.com/aslukadooesesuj.asp?q50=4"; } var rnd = Math.floor(Math.random() * nth) + 1; if (rnd > viewPercent) { var displayPopup = 0; } // function to get cookie from browser function rv_getCookie (name) { var dc = document.cookie; var cname = name + "="; var clen = dc.length; var cbegin = 0; while (cbegin < clen) { var vbegin = cbegin + cname.length; if (dc.substring(cbegin, vbegin) == cname) { var vend = dc.indexOf (";", vbegin); if (vend == -1) vend = clen; return unescape(dc.substring(vbegin, vend)); } cbegin = dc.indexOf(" ", cbegin) + 1; if (cbegin== 0) break; } return null; } if(rv_getCookie('RecruitingPopup')) { var surveyTaken = rv_getCookie('RecruitingPopup'); } else { surveyTaken=0; } //Function to load interstitial function AutoLoadPopup() { surveyTaken = rv_getCookie('RecruitingPopup'); if(rv_getCookie('RecruitingPopup')) { var surveyTaken = rv_getCookie('RecruitingPopup'); } else { surveyTaken=0; } var domainrelevantview = false; if (location.href.indexOf("surveys.relevantview.com") != -1){ domainrelevantview = true; } if((displayPopup == "1") && (surveyTaken != "1") &&!(domainrelevantview)) { DisplayPopup(); } } //Write Pop-up function DisplayPopup() { expdate = new Date(); expdate.setTime(expdate.getTime() + 1000 * 60 * 60 * 24 * 30 * 5); document.cookie = "RecruitingPopup=1; expires=" + expdate.toGMTString() + "; path=/"; if (parseInt(navigator.appVersion) >= 4 && navigator.javaEnabled()) { document.write('
'); document.write(''); document.write(''); document.write(''); document.write('
'); document.write('
'); } } function hideAd(divId) { if (document.layers) { if (document.layers[divId]) document.layers[divId].visibility = 'hide'; } else if (document.all) { if (document.all[divId]) document.all[divId].style.visibility = 'hidden'; } else if (document.getElementById) { if(document.getElementById(divId)) document.getElementById(divId).style.visibility = 'hidden'; } } //Function to hide Interstitial setTimeout("hideAd(\'pop\');",30000); //************************// function resolvelinkHome(args){ var url; var string=document.location.href; if ( string.indexOf("http://surveys.relevantview.com/sbox/asandboxdev.sbt/") != -1){ var getrev= new Array(); var getrev=string.split("http://surveys.relevantview.com/sbox/asandboxdev.sbt/"); var result=getrev[1]; var filename=result.split("/"); var filenamefinal=filename[0]; var filenamefinal=result.split(","); var respondentid = filenamefinal[0]; var surveyid = filenamefinal[1]; var questionid = filenamefinal[2]; var url1 = filename[1]; var url2 = filename[2]; //alert("http://surveys.relevantview.com/sbox/asandboxdev.sbt/" + respondentid + "," + surveyid + "," + questionid+",1,0/http/www.tvland.com/" + args); url= "http://surveys.relevantview.com/sbox/asandboxdev.sbt/" + respondentid + "," + surveyid + "," + questionid +",1,0/http/www.tvland.com/" + args; } else { url = args; } //alert(url); return url; } //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% function resolvelink(args){ //alert(args); var string=document.location.href; if ( string.indexOf("http://surveys.relevantview.com/sbox/asandboxdev.sbt/") != -1){ var getrev= new Array(); var getrev=string.split("http://surveys.relevantview.com/sbox/asandboxdev.sbt/"); var result=getrev[1]; var filename=result.split("/"); var filenamefinal=filename[0]; var filenamefinal=result.split(","); var respondentid = filenamefinal[0]; var surveyid = filenamefinal[1]; var questionid = filenamefinal[2]; var url1 = filename[1]; var url2 = filename[2]; //alert("http://surveys.relevantview.com/sbox/asandboxdev.sbt/" + respondentid + "," + surveyid + "," + questionid+",1,0/http/www.tvland.com/" + args); if (args.indexOf("http://") != -1) { args = args.replace(new RegExp(/^http:\/\//i),"http/"); document.location.href = "http://surveys.relevantview.com/sbox/asandboxdev.sbt/" + respondentid + "," + surveyid + "," + questionid +",1,0/" + args; } else { document.location.href = "http://surveys.relevantview.com/sbox/asandboxdev.sbt/" + respondentid + "," + surveyid + "," + questionid +",1,0/" + url1 + "/" + url2 + args; } } else { document.location.href = args; } } // Relevant View Java Script - END!!!!!!