<!--
var hidd = 0;

function MM_swapImgRestore() { //v3.0
   var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

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; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.0
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&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<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && document.getElementById) x=document.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}

function idle() {
   return;
}

function showsubmenu(id) {
   var x,y,obj;
   obj=document.all['menu'+id];
   obj.className='m'+id+'a';
   y=423 + obj.offsetHeight;
   x=0 + obj.offsetLeft;
   document.all['submenu'+id].style.top=y;
   document.all['submenu'+id].style.left=x;
   document.all['submenu'+id].style.visibility='visible';
}
function closesubmenu(id) {
   var obj;
   obj=document.all['menu'+id];
   obj.className='m'+id;
   document.all['submenu'+id].style.visibility='hidden';
}

function showsubmenuBottom(id) {
   var x,y,obj¡myObj;
   obj=document.all['menu'+id];
   obj.className='m'+id+'a';
   y=obj.offsetHeight;// + 923;
//alert(hmenu1table.style.top);
//   y = hmenu1table.style.top;

   myObj = hmenu1table;
//   y = 0;
    if (myObj.offsetParent)
    {
        while (myObj.offsetParent)
        {
            y += myObj.offsetTop;
            myObj = myObj.offsetParent;
        }
    }
    else if (myObj.y) {
        y += myObj.y;
    }
//alert(y);






   x=0 + obj.offsetLeft;
   document.all['submenu'+id].style.top=y;
   document.all['submenu'+id].style.left=x;
   document.all['submenu'+id].style.visibility='visible';
}
function closesubmenuBottom(id) {
   var obj;
   obj=document.all['menu'+id];
   obj.className='m'+id;
   document.all['submenu'+id].style.visibility='hidden';
}


var lastidblock = 2, lastid = 1;

function FlashBlock(idblock, id) {
   if (lastidblock != idblock) {
      ReturnBlock();
      lastid = 1;
   }

   document.all['block'+idblock+(lastid-1)+'a'].className='c2blockbg';
   document.all['block'+idblock+lastid].className='c2blockbg';
   document.all['block'+idblock+lastid+'a'].className='c2blockbg';

   document.all['block'+idblock+(id-1)+'a'].className='c2blockbga';
   document.all['block'+idblock+id].className='c2blockbga';
   document.all['block'+idblock+id+'a'].className='c2blockbga';

   lastidblock = idblock;
   lastid = id;
}

function ReturnBlock() {
   document.all['block'+lastidblock+(lastid-1)+'a'].className='c2blockbg';
   document.all['block'+lastidblock+lastid].className='c2blockbg';
   document.all['block'+lastidblock+lastid+'a'].className='c2blockbg';

   document.all['block'+lastidblock+'0a'].className='c2blockbga';
   document.all['block'+lastidblock+'1'].className='c2blockbga';
   document.all['block'+lastidblock+'1a'].className='c2blockbga';
}


function setDuration(transDuration,duration,gr) {
   var d=document;
   d.transDuration = transDuration;
   d.imgduration = duration;
   d.gr = gr;
}

function preloadImages() {
   var d=document;
   if(!d.rotimg) d.rotimg = new Array();
   if(!d.rotimgIndex) d.rotimgIndex = new Array();

   var argm = preloadImages.arguments;
   if(argm.length<1) return 0;
   var imgname=argm[0];
   var i,idximg=-1;
   for(i=0; i<d.rotimg.length;i++){
      if(d.rotimg[i][0]==imgname){
         idximg=i;
         break;
      }
   }
   if(idximg==-1){
      idximg=d.rotimg.length;
      d.rotimg[idximg]=new Array();
      d.rotimg[idximg][0]=imgname;
   }

   var l=d.rotimg[idximg].length;
   for(i=1; i<argm.length; i++){
      d.rotimg[idximg][l] = new Image();
      d.rotimg[idximg][l++].src=argm[i];
   }
   d.rotimgIndex[idximg]=1;
   d.rotimgcur=0;
}

function skipImage() {
   var i,d=document;
   for(i=0; i<d.gr;i++) {
      if(d.transDuration>0) d.all[d.rotimg[d.rotimgcur][0]].filters.item(0).Apply();
      d.all[d.rotimg[d.rotimgcur][0]].src=d.rotimg[d.rotimgcur][d.rotimgIndex[d.rotimgcur]++].src;
      if(d.transDuration>0) d.all[d.rotimg[d.rotimgcur][0]].filters(0).Play(d.transDuration);
      if(d.rotimgIndex[d.rotimgcur]>d.rotimg[d.rotimgcur].length-1) d.rotimgIndex[d.rotimgcur]=1;
      d.rotimgcur=d.rotimgcur+1;
      if(d.rotimgcur>d.rotimg.length-1) d.rotimgcur=0;
   }
   window.tm = setTimeout('skipImage()',d.imgduration);
}


function startRotate() {
   var i,d=document;
   if(d.transDuration>0) {
      for(i=0; i<d.rotimg.length; i++) {
         d.all[d.rotimg[i][0]].style.filter='blendtrans';
      }
   }
   window.tm = setTimeout('skipImage()',1);
}

function finishRotate(){
   clearTimeout(window.tm);
}


function printdoc() {
   window.print();
   return true;
}

function NewImgWindow(url, width, height) {
   var left = Math.round((screen.width/2)-(width/2));
   var top = Math.round((screen.height/2)-(height/2));
   FormWin = window.open(url, '', "width="+width+", height="+height+", menubar=no, resizable=no, scrollbars=no, status=no, border=no, toolbar=no, left="+left+", top="+top);
   FormWin.focus();
}


function NewImgWindow2(url, width, height) {
   var left = Math.round((screen.width/2)-(width/2));
   var top = Math.round((screen.height/2)-(height/2));
   FormWin = window.open(url, '', "width="+width+", height="+height+", menubar=no, resizable=no, scrollbars=yes, status=no, border=no, toolbar=no, left="+left+", top="+top);
   FormWin.focus();
}

function MailWindow(url, width, height) {
   var left = Math.round((screen.width/2)-(width/2));
   var top = Math.round((screen.height/2)-(height/2));
   FormWin = window.open(url, '', "width="+width+", height="+height+", menubar=no, resizable=no, scrollbars=no, status=no, border=no, toolbar=no, left="+left+", top="+top);
   FormWin.focus();
}

function tabsize(size1, table) {
   if (size1 > document.all[table].offsetHeight) {
      document.body.style.overflow='hidden';
   }
   return true;
}

// question start
function swapImgRestore() {
 var i,x,a=document.sr;
     for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function findObj(n, d) {
 var p,i,x;
   if(!d) d=document;
      if((p=n.indexOf("?"))>0&&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<d.forms.length;i++) x=d.forms[i][n];
   for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=findObj(n,d.layers[i].document);
   if(!x && document.getElementById) x=document.getElementById(n);
   return x;
}

function swapImage() {
 var i,j=0,x,a=swapImage.arguments;
   document.sr=new Array;
   for(i=0;i<(a.length-2);i+=3)
      if ((x=findObj(a[i]))!=null){
         document.sr[j++]=x;
         if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];
      }
}

function select(res){
      FormVoise.aid.value = res;
}

function CheckForm(){
   if (FormVoise.aid.value != ''){
      return FormVoise.submit = true;
      }
   else{
      alert ('________________________\n     Âûáåðèòå ëþáîé îòâåò\n è ñíîâà íàæìèòå íà êíîïêó\n           "ÎÒÂÅÒÈÒÜ"\n');
      return FormVoise.submit = false;
      }
}
// question end

function hidden() {
   if (hidd != 0) {
      document.body.style.overflow='hidden';
      MM_swapImage('b1','','img/radio.gif','1');
      hidd = 0;
   } else {
      document.body.style.overflow='';
      MM_swapImage('b1','','img/select.gif','1');
      hidd = 1;
   }
}


// ------------------------ ìàãàçèí --------------------------------


function blank() {;}
function objEdit(raw) {
  myWin=open('edit.php?raw='+raw,'FK','width=500,height=320,status=no,toolbar=no,scrollbars=no,resizable=no,screenX=200,screenY=150,left=20,top=150');
  if(!myWin.opener) {myWin.opener=self;}
  myWin.focus();
return false;
}
function objDelete(raw) {
  myWin=open('edit.php?delete='+raw,'FK','width=500,height=320,status=no,toolbar=no,scrollbars=no,resizable=no,screenX=200,screenY=150,left=20,top=150');
  if(!myWin.opener) {myWin.opener=self;}
  myWin.focus();
return false;
}
function objCopy(raw) {
  myWin=open('edit.php?copy='+raw,'FK','width=500,height=320,status=no,toolbar=no,scrollbars=no,resizable=no,screenX=200,screenY=150,left=20,top=150');
  if(!myWin.opener) {myWin.opener=self;}
  myWin.focus();
return false;
}
function cart(id,mode) {
    
    // Modified by Dmitri Maximov (amd) 21.08.2001
    //pWin=open('/dz/cart.php?id='+id,'FK','width=750,height=400,status=no,menubar=no,toolbar=no,scrollbars=yes,resizable=yes,screenX=200,screenY=150,left=20,top=150');
   
   switch (mode) {
      
      case "sale":
         pWin_sale=open('dz/cart.php?id='+id+'&admbase='+mode,'FK_sale','width=750,height=400,status=no,menubar=no,toolbar=no,scrollbars=yes,resizable=yes,screenX=200,screenY=150,left=20,top=150');
         pWin=pWin_sale;
         break;
      case "buy":
         pWin_buy=open('dz/cart.php?id='+id+'&admbase='+mode,'FK_buy','width=750,height=400,status=no,menubar=no,toolbar=no,scrollbars=yes,resizable=yes,screenX=200,screenY=150,left=20,top=150');
         pWin=pWin_buy;
         break;
      default:
         pWin=open('dz/cart.php?id='+id+'&admbase='+mode,'FK','width=750,height=400,status=no,menubar=no,toolbar=no,scrollbars=yes,resizable=yes,screenX=200,screenY=150,left=20,top=150');
   }
     //if(pWin.opener) {pWin.opener=self;}
    // End of modified code
     pWin.focus();
return false;
}



//-->
