if (this.name != 'CtrlWindow') this.name='shRLSMainWnd'; this.focus(); var imgSubCategory = ''; function Dimension(element){ this.x=-1; this.y=-1; this.w=0; this.h=0; if (element==document){ this.x=element.body.scrollLeft; this.y=element.body.scrollTop; this.w=element.body.clientWidth; this.h=element.body.clientHeight; }else if (element!=null){ var e=element; var left=e.offsetLeft; while ((e=e.offsetParent)!=null) { left+=e.offsetLeft; } var e=element; var top=e.offsetTop; while((e=e.offsetParent)!=null) { top+=e.offsetTop; } this.x=left; this.y=top; this.w=element.offsetWidth; this.h=element.offsetHeight; } } function showFilters(el, filterName) { var myEl = gE('filtrare['+filterName+']'); var maxWidth = el.offsetWidth; if(document.all) { myEl.style.marginTop = 15 + 'px'; myEl.style.marginLeft = -maxWidth + 'px'; } for(var i=0; i < myEl.childNodes.length; i++) if(myEl.childNodes[i].tagName == 'li' || myEl.childNodes[i].tagName == 'LI') { var compareMaxWidth = 0; if(document.all){ var htstring = myEl.childNodes[i].innerHTML; var auxString = htstring.replace(/(<([^>]+)>)/ig,""); compareMaxWidth = auxString.length * 7; } else var compareMaxWidth = myEl.childNodes[i].offsetWidth; if(maxWidth < compareMaxWidth) maxWidth = compareMaxWidth; } // alert(maxWidth+" | "+compareMaxWidth); //maxWidth -= 7; for(var i=0; i < myEl.childNodes.length; i++) if((myEl.childNodes[i].tagName == 'li' || myEl.childNodes[i].tagName == 'LI')) { myEl.childNodes[i].style.width = maxWidth + 'px'; // alert(myEl.childNodes[i].style.width); } } startList = function() { if (document.all && document.getElementById && document.getElementById("filtre")) { navRoot = document.getElementById("filtre"); for (var i=0; i 1024) ? 1024 : pwidth + 50; height = (pheight > 768) ? 768 : pheight + 50; content += '' + title + ''; content += ''; content += '
'; if(OpenWin) OpenWin.close(); if(pwidth > 1024 || pheight > 768) OpenWin = this.open('', "CtrlWindow", "width=" + width + ",height=" + height + " toolbar=no, menubar=no, location=no, scrollbars=no, statusbar=no, resizable=no, screenX="+x+", screenY="+y+", left="+x+", top="+y); else OpenWin = this.open('', "CtrlWindow", "width=" + width + ",height=" + height + " toolbar=no, menubar=no, location=no, scrollbars=no, statusbar=no, resizable=no, screenX="+x+", screenY="+y+", left="+x+", top="+y); OpenWin.document.write(content); OpenWin.focus(); } var maxNumberChecked = 2; var auxInc = 0; function checkCompare(el){ var compareFound = 0; // alert(document.forms[3].elements[1].name); for (var i in document.forms[3].elements) { // alert(i); var auxElName = (document.forms[3].elements[i]) ? String(document.forms[3].elements[i].name) : i; if(auxElName) if (auxElName.indexOf('compareToProductID[') >= 0) if(document.forms[3].elements[i].checked) compareFound++; } var doCompareBlock = (compareFound == maxNumberChecked); for (var i in document.forms[3].elements) { var auxElName = (document.forms[3].elements[i]) ? String(document.forms[3].elements[i].name) : i; if(auxElName) if (auxElName.indexOf('compareToProductID[') >= 0) if(!document.forms[3].elements[i].checked) document.forms[3].elements[i].disabled = doCompareBlock; } if(doCompareBlock) alert("Puteti compara maxim 3 produse."); } function vote(rank) { gE('rank').value = rank; for (i = 1; i <= 5; ++i) { if (i <= rank) gE('votImg' + i).style.border = '1px solid #000'; else gE('votImg' + i).style.border = '1px solid #fff'; } gE('body').focus(); } function popUpGallery(poza , widthO, heightO, basePath) { var x = (screen.width-widthO)/2; y = (screen.height-heightO)/2; OpenWin = this.open(basePath+"popup.html?poza="+poza+"&screenWidth="+widthO+"&screenHeight="+heightO, "CtrlWindow", "width="+widthO+",height="+heightO+" toolbar=no,menubar=no,location=no,scrollbars=no,resizable=no, screenX="+x+", screenY="+y+", left="+x+", top="+y); }