var OnlineOpinion=new Object();OnlineOpinion.util={SafeAddOnLoadEvent:function(B){if(!document.getElementById|!document.getElementsByTagName){return }var A=window.onload;if(typeof window.onload!="function"){window.onload=B}else{window.onload=function(){A();B()}}},SafeAddOnUnLoadEvent:function(A){if(!document.getElementById|!document.getElementsByTagName){return }var B=window.onunload;if(typeof window.onunload!="function"){window.onunload=A}else{window.onunload=function(){A();B()}}},popup:function(B,A,E){var C=window.open(B,A,E);if(typeof C=="undefined"){if(document.all){document.getElementById("test").href=B;document.getElementById("test").click()}else{var D=window.open(B,"_blank");D.focus()}}return false},DisableDeleteKey:function(A){this.DisableDeleteKeyObj=A},walkAnchors:function(H,A,G,D){var I=1000;var B=0;while(H&&A>0){B++;if(B>=I){var E=function(){OnlineOpinion.util.walkAnchors(H,A,G,D)};setTimeout(E,50);return }if(H.tagName=="A"){if(G.test(H.href)){H.onmousedown=function(){D.Preferences.Plugins.Events.poX=0}}}if(H.tagName=="INPUT"){if(H.type=="submit"||H.type=="image"){H.onmousedown=function(){D.Preferences.Plugins.Events.poX=0}}}if(H.tagName=="FORM"){if(typeof H.onsubmit!="function"){H.onsubmit=function(){D.Preferences.Plugins.Events.poX=0}}else{var F=H.onsubmit;H.onsubmit=function(){D.Preferences.Plugins.Events.poX=0;F()}}}if(H.nodeType==1){var C=/^(script|style|textarea)/i;if(!C.test(H.tagName)&&H.childNodes.length>0){H=H.childNodes[0];A++;continue}}if(H.nextSibling){H=H.nextSibling}else{while(A>0){H=H.parentNode;A--;if(H==null){break}if(H.nextSibling){H=H.nextSibling;break}}}}}};OnlineOpinion.cookie=function(){this.cookie_name="oo_r";this.expiration=24*60*60*1000;this.rhex=function(num){var hex_chr="0123456789abcdef",_s="";for(var j=0;j<=3;j++){_s+=hex_chr.charAt((num>>(j*8+4))&15)+hex_chr.charAt((num>>(j*8))&15)}return _s};this.str2blks_MD5=function(_s){var nblk=((_s.length+8)>>6)+1,blks=new Array(nblk*16);for(var i=0;i<nblk*16;i++){blks[i]=0}for(var i=0;i<_s.length;i++){blks[i>>2]|=_s.charCodeAt(i)<<((i%4)*8)}blks[i>>2]|=128<<((i%4)*8);blks[nblk*16-2]=_s.length*8;return blks};this._fSa=function(x,y){var lsw=(x&65535)+(y&65535),msw=(x>>16)+(y>>16)+(lsw>>16);return(msw<<16)|(lsw&65535)};this.rol=function(num,cnt){return(num<<cnt)|(num>>>(32-cnt))};this.cmn=function(q,a,b,x,s,t){return this._fSa(this.rol(this._fSa(this._fSa(a,q),this._fSa(x,t)),s),b)};this._fF=function(a,b,c,d,x,s){return this.cmn((b&c)|((~b)&d),a,0,x,s,0)};this._fG=function(a,b,c,d,x,s){return this.cmn((b&c)|(b&d)|(c&d),a,0,x,s,1518500249)};this._fH=function(a,b,c,d,x,s){return this.cmn(b^c^d,a,0,x,s,1859775393)};this._MD4=function(_s){var x=this.str2blks_MD5(_s),a=1732584193,b=-271733879,c=-1732584194,d=271733878;for(var i=0;i<x.length;i+=16){var olda=a,oldb=b,oldc=c,oldd=d;a=this._fF(a,b,c,d,x[i+0],3);d=this._fF(d,a,b,c,x[i+1],7);c=this._fF(c,d,a,b,x[i+2],11);b=this._fF(b,c,d,a,x[i+3],19);a=this._fF(a,b,c,d,x[i+4],3);d=this._fF(d,a,b,c,x[i+5],7);c=this._fF(c,d,a,b,x[i+6],11);b=this._fF(b,c,d,a,x[i+7],19);a=this._fF(a,b,c,d,x[i+8],3);d=this._fF(d,a,b,c,x[i+9],7);c=this._fF(c,d,a,b,x[i+10],11);b=this._fF(b,c,d,a,x[i+11],19);a=this._fF(a,b,c,d,x[i+12],3);d=this._fF(d,a,b,c,x[i+13],7);c=this._fF(c,d,a,b,x[i+14],11);b=this._fF(b,c,d,a,x[i+15],19);a=this._fG(a,b,c,d,x[i+0],3);d=this._fG(d,a,b,c,x[i+4],5);c=this._fG(c,d,a,b,x[i+8],9);b=this._fG(b,c,d,a,x[i+12],13);a=this._fG(a,b,c,d,x[i+1],3);d=this._fG(d,a,b,c,x[i+5],5);c=this._fG(c,d,a,b,x[i+9],9);b=this._fG(b,c,d,a,x[i+13],13);a=this._fG(a,b,c,d,x[i+2],3);d=this._fG(d,a,b,c,x[i+6],5);c=this._fG(c,d,a,b,x[i+10],9);b=this._fG(b,c,d,a,x[i+14],13);a=this._fG(a,b,c,d,x[i+3],3);d=this._fG(d,a,b,c,x[i+7],5);c=this._fG(c,d,a,b,x[i+11],9);b=this._fG(b,c,d,a,x[i+15],13);a=this._fH(a,b,c,d,x[i+0],3);d=this._fH(d,a,b,c,x[i+8],9);c=this._fH(c,d,a,b,x[i+4],11);b=this._fH(b,c,d,a,x[i+12],15);a=this._fH(a,b,c,d,x[i+2],3);d=this._fH(d,a,b,c,x[i+10],9);c=this._fH(c,d,a,b,x[i+6],11);b=this._fH(b,c,d,a,x[i+14],15);a=this._fH(a,b,c,d,x[i+1],3);d=this._fH(d,a,b,c,x[i+9],9);c=this._fH(c,d,a,b,x[i+5],11);b=this._fH(b,c,d,a,x[i+13],15);a=this._fH(a,b,c,d,x[i+3],3);d=this._fH(d,a,b,c,x[i+11],9);c=this._fH(c,d,a,b,x[i+7],11);b=this._fH(b,c,d,a,x[i+15],15);a=this._fSa(a,olda);b=this._fSa(b,oldb);c=this._fSa(c,oldc);d=this._fSa(d,oldd)}return this.rhex(a)+this.rhex(b)+this.rhex(c)+this.rhex(d)};this.read=function(n){var neq=n+"=";var ca=document.cookie.split(";");for(var i=0;i<ca.length;i++){var c=ca[i];while(c.charAt(0)==" "){c=c.substring(1,c.length)}if(c.indexOf(neq)==0){return unescape(c.substring(neq.length,c.length))}}return null};this.write=function(n,v){document.cookie=n+"="+v+";path=/;expires="+(new Date((new Date()).getTime()+this.expiration)).toGMTString()};this.matchurl=function(u){var i=0,c=this.read(this.cookie_name);n=this._MD4(u);if(c==null){return false}while(i<c.length){j=i+n.length;if(c.substring(i,j)==n){return(unescape(c.substring(j+1,j+2))==1)}i++}return false};this.tagurl=function(u){var prev_val="";if(this.read(this.cookie_name)!=null){prev_val=this.read(this.cookie_name).replace(eval("/"+escape(this._MD4(u))+"~1:/g"),"")}this.write(this.cookie_name,prev_val+(prev_val!=""?":":"")+escape(this._MD4(u))+"~1")}};OnlineOpinion.ocode=function(name){this.name=name;function rematch(val,restr){var re=new RegExp(restr);var m=re.exec(val);if(m==null||m==""){return""}else{var s="";for(i=0;i<m.length;i++){s=s+m[i]}return s}}this._fC=function(_u){_aT=this._sp+",\\/,\\.,-,_,"+this._rp+",%2F,%2E,%2D,%5F";_aA=_aT.split(",");for(i=0;i<5;i++){eval("_u=_u.replace(/"+_aA[i]+"/g,_aA[i+5])")}return _u};this._browser=function(){this.engine=null;this.version=null;var useragent=navigator.userAgent.toLowerCase();if(window.ActiveXObject){this.engine="ie";this.version=rematch(useragent,"msie\\s[0-9].[0-9]+").replace("msie ","")}else{if(window.opera){this.engine="opera";this.version=rematch(useragent,"opera.[0-9].[0-9]+").replace("opera","").replace("/","")}else{if(document.childNodes&&!document.all&&!navigator.taintEnabled){if(rematch(useragent,"applewebkit/[0-9]+")!=null){this.engine="webkit";this.version=rematch(useragent,"applewebkit/[0-9]+").replace("applewebkit/","")}else{this.engine="khtml";this.version=rematch(useragent,"khtml/[0-9].[0-9].[0-9]+").replace("khtml/","")}}else{if(navigator.userAgent.match(/gecko/i)){this.engine="gecko";this.version=rematch(useragent,"gecko/[0-9]+").replace("gecko/","")}}}}};this.serialize=function(obj,option){var str_out="",inc=0;for(var i in obj){if(typeof obj[i]!="function"&&typeof obj[i]!="undefined"&&obj[i]!=null&&obj[i]!=""){if(option==0){str_out+=(inc==0?"":"&")+i+"="+escape(obj[i])}else{if(option==1){str_out+=(inc==0?"":"|")+escape(obj[i])}}inc++}}return str_out};this.Preferences=new Object();this.Preferences.Persistence={enabled:true,cookie_page:true,cookie_name:"oo_r",expiration:24*60*60*1000};this.Preferences.Render={type:"floating",main_div_id:"oo_feedback_float",up_div_id:"olUp",over_div_id:"olOver",img_path:"/car-rental/images/us/en/oo_black.gif",feedback_span_id:"fbText",feedback_html:"FEEDBACK",click_html:"Click here to<br>rate this page",ty_html:""};this.Metrics=new Object();this.Metrics.core={width:screen.width,height:screen.height,referer:window.location.href,prev:document.referrer,time1:(new Date()).getTime(),time2:null};this.Metrics.custom=new Object();this.Preferences.Plugins=new Object();this.Preferences.Plugins.Events={poE:0,poX:0,poC:{id:"",value:0},poWC:0};this.onEntry=function(){if(Math.random()>=1-this.Preferences.Plugins.Events.poE){this.show();this.Preferences.Plugins.Events.poX=0}};this.onExit=function(){if(Math.random()>=1-this.Preferences.Plugins.Events.poX){this.show()}};this.OnClick=function(){if(Math.random()>=1-this.Preferences.Plugins.Events.poC){this.show();this.Preferences.Plugins.Events.poX=0;this.Preferences.Plugins.Events.poC=0}};this.Preferences.Plugins.URLRewrite={active:false,regex_search_pattern:"",regex_replace_pattern:""};this.Preferences.Plugins.CardOnPage={enabled:false,div_id:"onlineopinion_cc_window",iframe_id:"onlineopinion_cc_frame"};this.init=function(){if(typeof OnlineOpinion.cookie!="undefined"&&this.Preferences.Persistence.cookie_page){this.Cookie=new OnlineOpinion.cookie();if(typeof this.Preferences.Persistence.cookie_name!="undefined"){this.Cookie.cookie_name=this.Preferences.Persistence.cookie_name}this.Cookie.expiration=1000*this.Preferences.Persistence.expiration;if(this.Cookie.matchurl(this.Metrics.core.referer)==1){return false}}else{this.Cookie=null}document.onkeyup=this.KeyCheck};this.render=function(onclick_func){var b=new this._browser();var divID=this.Preferences.Render.main_div_id;if(b.engine==null||b.version==null||isNaN(parseInt(b.version))||(b.engine=="ie"&&parseFloat(b.version)<6)||(b.engine=="opera"&&parseInt(b.version)<8)||(b.engine=="gecko"&&parseInt(b.version)<20041107)){return false}if(document.getElementById(divID)==null){if(this.Preferences.Render.type=="floating"){var divObj=document.body.appendChild(document.createElement("div"));divObj.id=this.Preferences.Render.main_div_id}}var mainDivObj=document.getElementById(divID);if(mainDivObj.innerHTML==""){if(this.Preferences.Render.type=="floating"){if(this.Preferences.Persistence.enabled&&this.Preferences.Persistence.cookie_page){if(this.Cookie.matchurl(this.Metrics.core.referer)==1){return false}}var olUpObj=mainDivObj.appendChild(document.createElement("div"));olUpObj.id=this.Preferences.Render.up_div_id;var olOverObj=mainDivObj.appendChild(document.createElement("div"));olOverObj.id=this.Preferences.Render.over_div_id;olOverObj.style.display="none";olUpObj.onmouseover=function(){document.getElementById(olOverObj.id).style.display="block";document.getElementById(olUpObj.id).style.display="none"};olOverObj.onmouseout=function(){document.getElementById(olOverObj.id).style.display="none";document.getElementById(olUpObj.id).style.display="block"};var ooImg=olUpObj.appendChild(document.createElement("img"));ooImg.src=this.Preferences.Render.img_path;var fbText=olUpObj.appendChild(document.createElement("span"));fbText.id=this.Preferences.Render.feedback_span_id;fbText.innerHTML=this.Preferences.Render.feedback_html;olOverObj.innerHTML=this.Preferences.Render.click_html}if(this.Preferences.Render.type=="static"){mainDivObj.innerHTML=this.Preferences.Render.main_html}}if(this.Preferences.Render.type=="floating"){mainDivObj.style.bottom="0px";if(b.engine=="ie"&&(parseFloat(b.version)<7||document.compatMode!="CSS1Compat")){mainDivObj.style.position="absolute";mainDivObj.style.right="15px";var fixResizeScrollMethod=function(e){var db=document.body;if(parseFloat(b.version)==6&&document.compatMode=="CSS1Compat"){mainDivObj.style.bottom="0px"}else{mainDivObj.style.top=document.body.scrollTop+document.body.clientHeight-mainDivObj.clientHeight}};mainDivObj.attachEvent("onmouseover",fixResizeScrollMethod);mainDivObj.attachEvent("onmouseout",fixResizeScrollMethod);window.attachEvent("onresize",fixResizeScrollMethod);window.attachEvent("onscroll",fixResizeScrollMethod);window.attachEvent("onmousewheel",fixResizeScrollMethod);if(parseFloat(b.version)==7){window.attachEvent("onload",fixResizeScrollMethod)}}else{mainDivObj.style.position="fixed";mainDivObj.style.right="0px"}mainDivObj.style.visibility="visible"}mainDivObj.onclick=onclick_func;try{if(this.Preferences.Plugins.CardOnPage.enabled==true){var onPageCCdiv=document.body.appendChild(document.createElement("div"));onPageCCdiv.id=this.Preferences.Plugins.CardOnPage.div_id;var onPageCCiframe=onPageCCdiv.appendChild(document.createElement("iframe"));onPageCCiframe.id=this.Preferences.Plugins.CardOnPage.iframe_id;var W=(b.engine=="webkit")?window.innerWidth:(b.engine=="opera"?document.body.clientWidth:document.documentElement.clientWidth);var H=(b.engine=="webkit")?window.innerHeight:(b.engine=="opera"?document.body.clientHeight:document.documentElement.clientHeight);var w=585,h=400;onPageCCdiv.style.left=parseInt((W-w)/2)+"px";onPageCCdiv.style.top=parseInt((H-h)/2)+"px";if(b.engine=="ie"&&parseFloat(b.version)<7){onPageCCdiv.style.position="absolute"}}}catch(e){}};this.launchCC=function(){if(this.Preferences.Plugins.URLRewrite.active==true){this.Metrics.core.referer=this.Metrics.core.referer.replace(this.Preferences.Plugins.URLRewrite.regex_search_pattern,this.Preferences.Plugins.URLRewrite.regex_replace_pattern)}try{if(this.Cookie.matchurl(this.Metrics.core.referer)!=1){if(this.Preferences.Plugins.CardOnPage.enabled==true){document.getElementById(this.Preferences.Plugins.CardOnPage.iframe_id).src="https://secure.opinionlab.com/ccc01/comment_card.asp?"+(this.Preferences.Render.type=="asm"?"asm=1&":"")+"static=1&"+this.serialize(this.Metrics.core,0)+"&custom_var="+this.serialize(this.Metrics.custom,1);document.getElementById(this.Preferences.Plugins.CardOnPage.div_id).style.display="block"}else{OnlineOpinion.util.popup("https://secure.opinionlab.com/ccc01/comment_card.asp?"+(this.Preferences.Render.type=="asm"?"asm=1&":"")+this.serialize(this.Metrics.core,0)+"&custom_var="+this.serialize(this.Metrics.custom,1),"OnlineOpinion","resizable=yes,copyhistory=yes,scrollbars="+(this.Preferences.Render.type=="asm"?"yes":"no")+",location=no,status=no,fullscreen=no,width=545,height=200,top="+parseInt((this.Metrics.core.height-200)/2)+",left="+parseInt((this.Metrics.core.width-545)/2))}}}catch(e){OnlineOpinion.util.popup("https://secure.opinionlab.com/ccc01/comment_card.asp?"+(this.Preferences.Render.type=="asm"?"asm=1&":"")+this.serialize(this.Metrics.core,0)+"&custom_var="+this.serialize(this.Metrics.custom,1),"OnlineOpinion","resizable=yes,copyhistory=yes,scrollbars="+(this.Preferences.Render.type=="asm"?"yes":"no")+",location=no,status=no,fullscreen=no,width=545,height=200,top="+parseInt((this.Metrics.core.height-200)/2)+",left="+parseInt((this.Metrics.core.width-545)/2))}};this.show=function(){this.Metrics.core.time2=(new Date()).getTime();this.launchCC();if(this.Preferences.Persistence.enabled){document.getElementById(this.Preferences.Render.main_div_id).style.display="none"}if(this.Cookie!=null&&this.Preferences.Persistence.cookie_page){this.Cookie.tagurl(this.Metrics.core.referer)}this.Metrics.core.referer=window.location.href};this.post=function(){this.Metrics.core.time2=(new Date()).getTime();if(this.Preferences.Persistence.enabled&&this.Preferences.Render.ty_html==""){document.getElementById(this.Preferences.Render.main_div_id).style.display="none"}if(this.Preferences.Render.ty_html!=""){document.getElementById(this.Preferences.Render.main_div_id).innerHTML=this.Preferences.Render.ty_html}if(this.Cookie!=null&&this.Preferences.Persistence.cookie_page){this.Cookie.tagurl(this.Metrics.core.referer)}this.Metrics.core.referer=window.location.href;console.log("form submitted!")};this.KeyCheck=function(e){var KeyID=(window.event)?event.keyCode:e.keyCode;if(KeyID==8){try{OnlineOpinion.util.DisableDeleteKeyObj.Preferences.Plugins.Events.poX=0}catch(e){}}}};
