function openDetail(detailGUID,domain){ window.open("http://www.proautos."+domain+"/detail.php?GUID="+detailGUID,"_blank","menubar=no,toolbar=no,scrollbars=yes,width=635,height=600"); } function openBazarDetail(detailGUID,bazarNick,domain){ window.open("http://"+bazarNick+".proautos."+domain+"/detail.php?GUID="+detailGUID,"_blank","menubar=no,toolbar=no,scrollbars=yes,width=635,height=600"); } function openImage(imgSrc){ window.open(imgSrc,"_blank","menubar=no,toolbar=no,scrollbars=yes,width=820,height=600"); } function openPersonRule(){ window.open("rulePersonCS.html","_blank","statusbar=no,menubar=no,toolbar=no,scrollbars=yes,width=750,height=620"); } function openFirmRule(){ window.open("ruleFirmCS.html","_blank","statusbar=no,menubar=no,toolbar=no,scrollbars=yes,width=750,height=620"); } function showPrevPhoto(actualPhoto, total) { var i; var prevPhoto; actualPhoto = parseInt(actualPhoto); total = parseInt(total); if(actualPhoto > 1) { for(i=1;i<=total;i++){ document.getElementById('detailPhoto' + i).style.display = 'none'; } prevPhoto = parseInt(actualPhoto) - 1; document.getElementById('detailPhoto' + prevPhoto).style.display = 'block'; } } function showNextPhoto(actualPhoto, total) { var i; var nextPhoto; actualPhoto = parseInt(actualPhoto); total = parseInt(total); if(actualPhoto < total) { for(i=1;i<=total;i++){ document.getElementById('detailPhoto' + i).style.display = 'none'; } nextPhoto = parseInt(actualPhoto) + 1; document.getElementById('detailPhoto' + nextPhoto).style.display = 'block'; } } function updateText() { //alert("jede"); //var text = "WwigGzIaZ38.107.179.237"; //alert(text); document.magazin_detail.mobil.value="WwigGzIaZ"; } function ElementPosition(element) { var el = document.getElementById(element); var zvrchu = 0; var zleva = 0; var par; var ael; if( el ) { zvrchu = el.offsetTop - 15; zleva = el.offsetLeft; ael = el; par = ael.offsetParent; while( par.tagName != "BODY" ) { zvrchu += par.offsetTop; zleva += par.offsetLeft; par = par.offsetParent; } return Array(zvrchu, zleva); } else {return false;} } function EnableSubmenu(mainmenu) { var smenu = document.getElementById('submenu-'+mainmenu); var mmenupos = ElementPosition('menu-hlavni-'+mainmenu); smenu.style.left = mmenupos[1] + 'px'; smenu.style.top = (mmenupos[0]+32)+'px'; smenu.style.display = 'block'; } function DisableSubmenu(mainmenu) { document.getElementById('submenu-'+mainmenu).style.display = 'none'; } window.onscroll= function(e) { var posunuti = document.getElementById('page').offsetHeight; //alert(posunuti); if (navigator.appName == "Microsoft Internet Explorer") { margin = document.documentElement.scrollTop; footerHeight = 180; } else { margin = window.pageYOffset; footerHeight = 160; } //alert('body: '+bodyHeight+'\nbanner: '+bannerHeight+'\nmargin: '+margin+'\nfooter: '+footerHeight); var banner = document.getElementById('banner-absolute'); if(banner) { if(margin > 63 && margin <= (posunuti-620)) banner.style.top = margin + 'px'; else if(margin <= 63) banner.style.top = '63px'; } //window.document.getElementById('content_right_banner').style.marginTop = margin + 'px'; } /* POSOUVAC BANNERU -----------------------------------------------------------------------------*/ //document.onscroll = bannerScroll; function alertSize() { var myWidth = 0, myHeight = 0, posunuti = 0; if( typeof( window.innerWidth ) == 'number' ) { //Non-IE myWidth = window.innerWidth; myHeight = window.innerHeight; } else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) { //IE 6+ in 'standards compliant mode' myWidth = document.documentElement.clientWidth; myHeight = document.documentElement.clientHeight; } else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) { //IE 4 compatible myWidth = document.body.clientWidth; myHeight = document.body.clientHeight; } var elem01 = document.getElementById('banner-absolute'); if(elem01) { if(myWidth > 914) posunuti = ((myWidth - 914) / 2) + 924; else posunuti = 924; elem01.style.left = posunuti + 'px'; } } onresize = alertSize; onload = function () { alertSize(); }