function onLoadEvents(a){if((document.najdiSForm)&&(a)){document.najdiSForm.q.focus()}}function toggleDictionaryType(a){$("dictType_other").hide();var b=new Array("SLOEN","ENSLO","SLOGER","GERSLO","SLOSPA","SPASLO","SLOITA","ITASLO","SLOFRA","FRASLO");for(var c=0;c<b.length;c++){try{$("dictType_"+b[c]).hide()}catch(d){}try{$("dictLang"+b[c].replace("SLO","")).style.color="#4963ad";$("dictLang"+b[c].replace("SLO","")).style.textDecoration="underline";$("dictLang"+b[c].replace("SLO","")).style.fontWeight="normal"}catch(d){}}var f=false;try{$("dictType_"+a+"SLO").show();f=true}catch(d){}try{$("dictType_SLO"+a).show();f=true}catch(d){}try{$("dictLang"+a).style.textDecoration="none";$("dictLang"+a).style.color="#000";$("dictLang"+a).style.fontWeight="bold"}catch(d){}if(!f){$("dictType_other").show();$("dictType_other").innerHTML="Prevod v tem jeziku ne obstaja!"}}function markSwitchOnSession(c,e){var b=document.cookie.match(c+"="+e+"(.*?)(;|$)");if(!b){var a=new Date();a=new Date(a.getTime()+(365*24*60*60*1000));var f="; path=/";var d=(document.domain.indexOf(".najdi.si")!=-1)?"; domain=.najdi.si":"";document.cookie=c+"="+e+d+f}}function markSwitchOn(d,f){var c=document.cookie.match(d+"="+f+"(.*?)(;|$)");if(!c){var b=new Date();b=new Date(b.getTime()+(365*24*60*60*1000));var a="; expires="+b.toGMTString();var g="; path=/";var e=(document.domain.indexOf(".najdi.si")!=-1)?"; domain=.najdi.si":"";document.cookie=d+"="+f+a+e+g}}function markSwitchOff(d){var c=document.cookie.match(d+"=(.*?)(;|$)");if(c){var b=new Date();b.setTime(b.getTime()-(3600*1000));var a="; expires="+b.toGMTString();var f="; path=/";var e=(document.domain.indexOf(".najdi.si")!=-1)?"; domain=.najdi.si":"";document.cookie=d+"="+a+e+f}}function getCookieVal(b){var a=document.cookie.match(b+"=(.*?)(;|$)");return a}function switch_style(c,a){if(document.getElementById("themeStyle")!=null){document.getElementsByTagName("head")[0].removeChild(document.getElementById("themeStyle"))}var b=document.createElement("link");b.setAttribute("id","themeStyle");b.setAttribute("rel","stylesheet");b.setAttribute("type","text/css");b.setAttribute("href",a);if(typeof b!="undefined"){document.getElementsByTagName("head")[0].appendChild(b)}markSwitchOn("theme_style",c)}function switch_styleOld(b){var a,c;for(a=0,c=document.getElementsByTagName("link");a<c.length;a++){if((c[a].rel.indexOf("stylesheet")!=-1)&&c[a].title){c[a].disabled=true;if(c[a].title==b){c[a].disabled=false;markSwitchOn("theme_style",b)}}}}function callAdPartnerURL(g){try{var c=g.indexOf("cli=")+4;if(c!=3){var b=g.substring(c,g.length);var a=b.indexOf("&");var d=b.substring(0,a);g=g.replace(d,clientFingerprint())}window.location=g}catch(f){return true}return false}var totalPageViewTime=0;var imageUrlWithCampaignId="";function logPageViewData(){totalPageViewTime+=0.5}var statisticsHashMap;var coverageCountsPerSecond=2;var imageUrlWithCampaignId="";function logPPCoverageCount(f,e,d){if(statisticsHashMap==null){statisticsHashMap=new Hash()}if(e>0.5){var c=statisticsHashMap.get(f);if(c==null){c=new Hash();c.set("campaignId",getCampaignIdFromClickUrl(d));c.set("observationSerp",0.5)}else{var a=c.get("observationSerp");var b=isNaN(a)?0:a;c.set("observationSerp",b+0.5)}statisticsHashMap.set(f,c)}}function logPPCoverageSerp(){logPPCoverage("serp")}function logPPCoverageIframe(){logPPCoverage("iframe")}function logPPCoverage(c){if(statisticsHashMap==null){statisticsHashMap=new Hash()}statisticsHashMap.set("exposureSerp",totalPageViewTime);statisticsHashMap.set("sourcePage",c);var b="${coverage.tracker.url}";if(b!=""){var a=document.createElement("script");a.setAttribute("src",b+"?statisticsData="+encodeURIComponent(statisticsHashMap.toJSON()));a.setAttribute("type","text/javascript");document.getElementsByTagName("HEAD")[0].appendChild(a)}}function getCampaignIdFromClickUrl(g){var a=-1;try{var c=g.indexOf("ms/ads/")+7;var b=g.substring(c,g.length);var d=b.indexOf("/");a=b.substring(0,d)}catch(f){return a}return a}function observePP(){Event.observe(window,"load",function(){var f=document.getElementById("sp_div1");if(f){var c=f.getElementsByTagName("img")[0];if(c!=null&&c.id=="img_pp"){Viewport.trackCoverage(f,function(g,h){logPPCoverageCount(g.id,h,c.src)})}}var e=document.getElementById("sp_div2");if(e){var b=e.getElementsByTagName("img")[0];if(b!=null&&b.id=="img_pp"){Viewport.trackCoverage(e,function(g,h){logPPCoverageCount(g.id,h,b.src)})}}var d=document.getElementById("sp_div3");if(d){var a=d.getElementsByTagName("img")[0];if(a!=null&&a.id=="img_pp"){Viewport.trackCoverage(d,function(g,h){logPPCoverageCount(g.id,h,a.src)})}}});Event.observe(window,"unload",logPPCoverageSerp)}var whitespace=" \t\n\r";function isEmpty(a){return((a==null)||(a.length==0))}function trim(a){a=this!=window?this:a;return a.replace(/^\s+|\s+$/g,"")}String.prototype.trim=trim;function trimLeading(a){if(isEmpty(a)){return a}return str.replace(/^\s+/g,"")}function trimTrailing(a){if(isEmpty(a)){return a}return str.replace(/\s+$/g,"")}function isWhitespace(a){if(isEmpty(a)){return true}return trim(a).length==0}function containsWhitespace(b){if(isEmpty(b)){return false}var a;for(a=0;a<whitespace.length;a++){if(b.indexOf(whitespace.charAt(a))>=0){return true}}return false}function trimTextFields(b){var a=0;for(a=0;a<b.elements.length;a++){if("text"==b.elements[a].type||"textarea"==b.elements[a].type){b.elements[a].value=trim(b.elements[a].value)}}return true}function replace(b,a,c){while(b.indexOf(a)>=0){b=b.replace(a,c)}return b}function isEmailValid(a){var c=a.length-1;var d=a.indexOf("@");if(d<=0||d==c){return false}var b=a.substring(d+1);if(!isHostValid(b)){return false}return true}function isNameOrEmailValid(c){if(isEmpty(c)){return false}if(c.indexOf(",")>0){return false}var d=c.indexOf("<");var a=c.indexOf(">");if(0<=d&&0<a&&d<a){var b=c.substring(d+1,a);if(isEmailValid(b)){return true}else{return false}}if(c.indexOf("@")>0){return isEmailValid(c)}return true}function isURLValid(k){if(isEmpty(k)){return false}if(k.length<11){return false}k=k.toLowerCase();var b=["http","https"];var d=k.indexOf("://");if(d<0){return false}var h=k.substring(0,d);var c=0;var g=false;for(c=0;c<b.length;c++){if(b[c]==h){g=true;break}}if(!g){return false}var j=k.substring(d+3);var f=j.indexOf("/");var a=j.indexOf("?");if(f<0){f=j.length}if(a<0){a=j.length}var e=Math.min(f,a);if(e<j.length){j=j.substring(0,e)}if(!isHostValid(j)){return false}return true}function isHostValid(a){if(isEmpty(a)){return false}if(a.length<4){return false}var b=a.indexOf(".");if(b<=0){return false}b=a.lastIndexOf(".");if(b==(a.length-1)){return false}return true}function trimValues(b){if(b!=null){var a;for(a=0;a<b.elements.length;a++){b.elements[a].value=trim(b.elements[a].value)}}}function tokenizeRaw(d,g){if(isEmpty(d)){return null}var f=[];var b;var e=0;var a;for(a=0;a<d.length;a++){if(d.charAt(a)==g){b=d.substring(e,a);f[f.length]=b;e=a+1}}if(e<d.length){b=d.substring(e);f[f.length]=b}return f}function tokenize(d,g){if(isEmpty(d)){return null}var f=[];var b;var e=0;var a;for(a=0;a<d.length;a++){if(d.charAt(a)==g){b=d.substring(e,a);f[f.length]=getAddress(b);e=a+1}}if(e<d.length){b=d.substring(e);f[f.length]=getAddress(b)}return f}function getAddress(c){if(c==null){return null}var d=c.indexOf("<");var b=c.lastIndexOf(">");var a=null;if(0<d&&0<b&&d<b){a=c.substring(d+1,b)}else{a=c}if(a!=null){d=a.indexOf("<");b=a.lastIndexOf(">");if(0<d||0<b){return null}}a=trim(a);if(containsWhitespace(a)){return null}else{if(isEmailValid(a)){return a}else{return null}}}function areEmailsValid(b){var c=tokenize(b,",");if(isEmpty(c)){return -1}else{var a;for(a=0;a<c.length;a++){if(isEmpty(c[a])){return a}}}return -1}var disappeardelay=250;var enableanchorlink=0;var hidemenu_onclick=1;var ie5=document.all;var ns6=document.getElementById&&!document.all;function getposOffset(d,c){var b=(c=="left")?d.offsetLeft:d.offsetTop;var a=d.offsetParent;while(a!=null){b=(c=="left")?b+a.offsetLeft:b+a.offsetTop;a=a.offsetParent}return b}function showhide(b,c,a){if(ie5||ns6){dropmenuobj.style.left=dropmenuobj.style.top=-500}if(b.display==a){b.display=c}else{b.display=a}}function iecompattest(){return(document.compatMode&&document.compatMode!="BackCompat")?document.documentElement:document.body}function clearbrowseredge(e,c){var b=0;if(c=="rightedge"){var d=ie5&&!window.opera?iecompattest().scrollLeft+iecompattest().clientWidth-15:window.pageXOffset+window.innerWidth-15;dropmenuobj.contentmeasure=dropmenuobj.offsetWidth;if(d-dropmenuobj.x<dropmenuobj.contentmeasure){b=dropmenuobj.contentmeasure-e.offsetWidth}}else{var a=ie5&&!window.opera?iecompattest().scrollTop:window.pageYOffset;var d=ie5&&!window.opera?iecompattest().scrollTop+iecompattest().clientHeight-15:window.pageYOffset+window.innerHeight-18;dropmenuobj.contentmeasure=dropmenuobj.offsetHeight;if(d-dropmenuobj.y<dropmenuobj.contentmeasure){b=dropmenuobj.contentmeasure+e.offsetHeight;if((dropmenuobj.y-a)<dropmenuobj.contentmeasure){b=dropmenuobj.y+e.offsetHeight-a}}}return b}function dropdownmenu(b,a){if(typeof dropmenuobj!="undefined"){dropmenuobj.style.display="none"}clearhidemenu();if(ie5||ns6){b.onmouseout=delayhidemenu;dropmenuobj=document.getElementById(a);if(hidemenu_onclick){dropmenuobj.onclick=function(){dropmenuobj.style.display="none"}}dropmenuobj.onmouseover=clearhidemenu;dropmenuobj.onmouseout=ie5?function(){dynamichide(event)}:function(c){dynamichide(c)};showhide(dropmenuobj.style,"block","none");dropmenuobj.x=getposOffset(b,"left");dropmenuobj.y=getposOffset(b,"top");dropmenuobj.style.left=dropmenuobj.x-clearbrowseredge(b,"rightedge")+"px";dropmenuobj.style.top=dropmenuobj.y-clearbrowseredge(b,"bottomedge")+b.offsetHeight+"px"}return clickreturnvalue()}function clickreturnvalue(){if((ie5||ns6)&&!enableanchorlink){return false}else{return true}}function contains_ns6(d,c){while(c.parentNode){if((c=c.parentNode)==d){return true}}return false}function dynamichide(a){if(ie5&&!dropmenuobj.contains(a.toElement)){delayhidemenu()}else{if(ns6&&a.currentTarget!=a.relatedTarget&&!contains_ns6(a.currentTarget,a.relatedTarget)){delayhidemenu()}}}function delayhidemenu(){delayhide=setTimeout("dropmenuobj.style.display='none'",disappeardelay)}function clearhidemenu(){if(typeof delayhide!="undefined"){clearTimeout(delayhide)}};
