this.focus(); function getElementPosition(elemID) { var offsetTrail = document.getElementById(elemID); var offsetLeft = 0; var offsetTop = 0; while (offsetTrail) { offsetLeft += offsetTrail.offsetLeft; offsetTop += offsetTrail.offsetTop; offsetTrail = offsetTrail.offsetParent; } if (navigator.userAgent.indexOf("Mac") != -1 && typeof document.body.leftMargin != "undefined") { offsetLeft += document.body.leftMargin; offsetTop += document.body.topMargin; } return {left:offsetLeft, top:offsetTop}; } function MM_preloadImages() { //v3.0 var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array(); var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; 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 0) { //// alert('here'); // fillSelect('catID3', arrValues, document.forms[formName].elements(selectName), formName); // } // // if (selectName.indexOf('3') > 0) { //// alert('here'); // fillSelect('catID4', arrValues, document.forms[formName].elements(selectName), formName); // } } else { s.parentElement.style.display = 'none'; } } function _fillSelect(selectName, arrValues, indexEl, formName) { if (formName == "") formName = "catEditFrm" d = document.forms[formName]; s = d.elements(selectName); // alert(indexEl); if (indexEl.options && indexEl.options.length) { var index = indexEl.options[indexEl.selectedIndex].value; // alert(selectName + " - " + index) s.options.length = 0; var k = 0; for (var i in arrValues[index]) { s.options[k++] = new Option(arrValues[index][i], i); } if (index == 0 || !k) { s.parentElement.style.display = 'none'; } else s.parentElement.style.display = 'inline'; if (selectName.indexOf('2') > 0) { fillSelect('catID3', arrValues, document.forms[formName].elements(selectName), formName); } } else s.parentElement.style.display = 'none'; } function popUp(urlToOpen) { var x = (screen.width-800)/2; y = (screen.height-600)/2; OpenWin = this.open(urlToOpen, "CtrlWindow", "width=800,height=600, toolbar=no,menubar=no,location=no,scrollbars=no,resizable=no, screenX="+x+", screenY="+y+", left="+x+", top="+y); } function gE(elName) { // alert(document.getElementById(elName)); return document.getElementById(elName); } function ToggleMandatoryOrderDetails(el){ if(el.value == 1){ gE('judicialPersonInfo').style.display = 'none'; gE('physicalPersonInfo').style.display = ''; } else{ gE('judicialPersonInfo').style.display = ''; gE('physicalPersonInfo').style.display = 'none'; } } function ClearEmail(elem){ if(elem.value=='adresa de email') elem.value = ""; } function show_flash(id) { document.getElementById(id).outerHTML = document.getElementById(id).outerHTML; } var OpenWin; function imgPopup(file, pwidth, pheight, title) { var content = ''; var x = (screen.width-pwidth)/2; y = (screen.height-pheight)/2; //y = 10; width = (pwidth > 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(); } function opacity(id, opacStart, opacEnd, millisec) { //speed for each frame var speed = Math.round(millisec / 100); var timer = 0; //determine the direction for the blending, if start and end are the same nothing happens if(opacStart > opacEnd) { for(i = opacStart; i >= opacEnd; i--) { setTimeout("changeOpac(" + i + ",'" + id + "')",(timer * speed)); timer++; } } else if(opacStart < opacEnd) { for(i = opacStart; i <= opacEnd; i++) { setTimeout("changeOpac(" + i + ",'" + id + "')",(timer * speed)); timer++; } } } //change the opacity for different browsers function changeOpac(opacity, id) { var object = document.getElementById(id).style; object.opacity = (opacity / 100); object.MozOpacity = (opacity / 100); object.KhtmlOpacity = (opacity / 100); object.filter = "alpha(opacity=" + opacity + ")"; } function getScrollXY() { var scrOfX = 0, scrOfY = 0; if( typeof( window.pageYOffset ) == 'number' ) { //Netscape compliant scrOfY = window.pageYOffset; scrOfX = window.pageXOffset; } else if( document.body && ( document.body.scrollLeft || document.body.scrollTop ) ) { //DOM compliant scrOfY = document.body.scrollTop; scrOfX = document.body.scrollLeft; } else if( document.documentElement && ( document.documentElement.scrollLeft || document.documentElement.scrollTop ) ) { //IE6 standards compliant mode scrOfY = document.documentElement.scrollTop; scrOfX = document.documentElement.scrollLeft; } return [ scrOfX, scrOfY ]; } function alertSize() { var myWidth = 0, myHeight = 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 windowSize=myWidth+','+myHeight; //window.alert( 'Width = ' + myWidth ); //window.alert( 'Height = ' + myHeight ); return [ myWidth, myWidth]; } function closeAgremment(){ var dinamicDiv=document.getElementById('agremmentBox'); document.body.removeChild(dinamicDiv); opacity('grayBackground', 70, 0, 1000); var dinamicDiv=document.getElementById('grayBackground'); document.body.removeChild(dinamicDiv); } function delay(newdiv){ //document.body.appendChild(newdiv); } function productAgreement(bannerPath){ //var windowSize=alertSize(); //var sizeArray=windowSize.split(","); //var sizeArray=alertSize(); //var scrollArray=getScrollXY(); var topElement=getElementPosition('meniu'); var bottomElement=getElementPosition('footer'); //alert (topElement['left']+' , '+topElement['top']+' | '+bottomElement['left']+' , '+bottomElement['top']); var shadowLayerHeight=bottomElement['top']-topElement['top']+80; var alldiv = document.createElement('div'); alldiv.setAttribute('id', 'grayBackground'); alldiv.style.position = "absolute"; alldiv.style.width = 900; alldiv.style.height = shadowLayerHeight; alldiv.style.left = topElement['left']; alldiv.style.top = topElement['top']; alldiv.style.background = "#E3E3E3"; alldiv.style.border = "0px solid #000"; alldiv.style.padding = "0px"; alldiv.style.opacity = 0; alldiv.style.MozOpacity = 0; alldiv.style.KhtmlOpacity = 0; alldiv.style.filter = "alpha(opacity=" + opacity + ")"; document.body.appendChild(alldiv); opacity('grayBackground', 0, 70, 1000); //opacity('stanga', 100, 0, 500); //opacity('dreapta', 100, 0, 500); var banner=getElementPosition('fereastra_gri_centru'); //alert(ceva['left']+' , '+ceva['top']); var newdiv = document.createElement('div'); newdiv.setAttribute('id', 'agremmentBox'); newdiv.style.position = "absolute"; newdiv.style.width = 500; newdiv.style.height = 100; newdiv.style.left = banner['left']-500; newdiv.style.top = banner['top']+50; newdiv.style.background = "#FFFFFF"; newdiv.style.border = "1px solid #000"; newdiv.style.padding = "10px"; newdiv.className = "text"; var divText='
In conformitate cu legislatia in vigoare, accesul la paginile cu informatii despre medicamente este permis numai profesionistilor (medici, farmacisti).

Acceptand sa continuati accesarea sectiuni declarati pe propria raspundere ca sunteti cadru medical.

 
'; newdiv.innerHTML = divText; /* if (html) { newdiv.innerHTML = html; } else { newdiv.innerHTML = "nothing"; } */ setTimeout("delay()",1000); document.body.appendChild(newdiv) } var xmlHttp function getVote(int,pollID,path) { xmlHttp=GetXmlHttpObject() if (xmlHttp==null) { alert ("Browser does not support HTTP Request") return } var divLoader=document.getElementById('showPoll'); divLoader.innerHTML=''; var url=path+"pollVote.php" url=url+"?vote="+int url=url+"&poll="+pollID url=url+"&sid="+Math.random() xmlHttp.onreadystatechange=stateChanged xmlHttp.open("GET",url,true) xmlHttp.send(null) } function stateChanged() { if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete") { response=xmlHttp.responseText; if (response=="notOK"){ alert('Votul nu a fost inregistrat corespunzator'); } else if (response=="alreadyVote"){ alert('Ati votat deja la acest sondaj.'); } else{ //alert(response); var percents=response.split(";"); for (i=0;i