//============================================================================

function Img(p,dp) {
  return eval("document.image"+p+".src='images/"+dp+"'");
}


function Res(s,ds) {
  return eval("document.image"+s+".src='images/"+ds+"'");
}

//============================================================================

function getLeftPos(Obj)
{
   var aaa = Obj.offsetLeft;
   while(Obj.offsetParent!=null)
   {
     Obj = Obj.offsetParent;

     aaa+=Obj.offsetLeft;
   }
   return aaa;
}

function getTopPos(Obj3)
{
   var ccc = Obj3.offsetTop;
   while(Obj3.offsetParent!=null)
   {
     Obj3= Obj3.offsetParent;

     ccc+=Obj3.offsetTop;
   }
   return ccc;
}

function showObject(dId, aId)
{
  aObj = document.getElementById(aId);
  dObj = document.getElementById(dId);
  dObj.style.visibility = "visible";
   
  dObj.style.position = "absolute";
  dObj.style.top = getTopPos(aObj)+72;
  
  dObj.style.left = getLeftPos(aObj);
}

//============================================================================

function showObject2(dId, aId)
{
  aObj = document.getElementById(aId);
  dObj = document.getElementById(dId);
  mObj = document.getElementById('m1');
  dObj.style.visibility = "visible";
   
  dObj.style.position = "absolute";
  dObj.style.top = aObj.offsetTop-1;
  
  //dObj.style.left = mObj.offsetLeft-4;
    
  //if(screen.Width <= 800) dObj.style.left = getLeftPos(aObj);
  //if((screen.Width > 800) && (screen.Width <= 1024))
  if(screen.Width > 1024) if(aId=='link_06_01') dObj.style.left = getLeftPos(mObj);
}

//============================================================================

function hideObject(dId, aId)
{
  document.getElementById(dId).style.visibility = "hidden";
}

//============================================================================

function Screen() {
  var r=screen.Width;
  if (r<=800) document.write('<LINK href="style_800.css" rel=stylesheet>');
  if ((r>800) && (r<=1024)) document.write('<LINK href="style_1024.css" rel=stylesheet>');
  if (r>1024) document.write('<LINK href="style.css" rel=stylesheet>');
}

//============================================================================

function order()
{
document.getElementById('send').className = 'VisibleSend';
}

function button_hr(id, a, na) {
idd=id+"_hid";
eval ("if (document.all."+idd+".style.display=='none') { document.all."+idd+".style.display='block'; document.all."+id+".className='"+a+"';} else { document.all."+idd+".style.display='none'; document.all."+id+".className='"+na+"';}");
}

//============================================================================
function testfunc(m){
  name = new String("test");
  name=name+String(m);
  eval ("if (document.all."+name+".style.display=='none') { document.all."+name+".style.display='block'; } else { document.all."+name+".style.display='none';}");
}
function test(n) {
  name = new String("test");
  name=name+String(n);
  document.write('<a href="#" onclick="testfunc('+n+')" class="test">'+name+'</a>');
  document.write('<div id="'+name+'" style="display: none" onclick="testfunc('+n+')">');
  document.write('<table bgcolor="#FFFF00"><tr><td><img src="images/void.gif" alt="" width="1000" height="1000" border="1"></td></tr></table></div>');
}


