// <script>਀ 
// Copyright (C) 2005 Ilya S. Lyubinskiy. All rights reserved.਀⼀⼀ 吀攀挀栀渀椀挀愀氀 猀甀瀀瀀漀爀琀㨀 栀琀琀瀀㨀⼀⼀眀眀眀⸀瀀栀瀀ⴀ搀攀瘀攀氀漀瀀洀攀渀琀⸀爀甀⼀ 
//਀⼀⼀ 夀伀唀 䴀䄀夀 一伀吀 
// (1) Remove or modify this copyright notice.਀⼀⼀ ⠀㈀⤀ 䐀椀猀琀爀椀戀甀琀攀 琀栀椀猀 挀漀搀攀Ⰰ 愀渀礀 瀀愀爀琀 漀爀 愀渀礀 洀漀搀椀昀椀攀搀 瘀攀爀猀椀漀渀 漀昀 椀琀⸀ 
//     Instead, you can link to the homepage of this code:਀⼀⼀     栀琀琀瀀㨀⼀⼀眀眀眀⸀瀀栀瀀ⴀ搀攀瘀攀氀漀瀀洀攀渀琀⸀爀甀⼀樀愀瘀愀猀挀爀椀瀀琀猀⼀猀洀愀爀琀ⴀ昀漀爀洀猀⸀瀀栀瀀⸀ 
//਀⼀⼀ 夀伀唀 䴀䄀夀 
// (1) Use this code on your website.਀⼀⼀ ⠀㈀⤀ 唀猀攀 琀栀椀猀 挀漀搀攀 愀猀 愀 瀀愀爀琀 漀昀 愀渀漀琀栀攀爀 瀀爀漀搀甀挀琀 瀀爀漀瘀椀搀攀搀 琀栀愀琀 
//     its main use is not creating javascript menus.਀⼀⼀ 
// NO WARRANTY਀⼀⼀ 吀栀椀猀 挀漀搀攀 椀猀 瀀爀漀瘀椀搀攀搀 ∀愀猀 椀猀∀ 眀椀琀栀漀甀琀 眀愀爀爀愀渀琀礀 漀昀 愀渀礀 欀椀渀搀Ⰰ 攀椀琀栀攀爀 
// expressed or implied, including, but not limited to, the implied warranties਀⼀⼀ 漀昀 洀攀爀挀栀愀渀琀愀戀椀氀椀琀礀 愀渀搀 昀椀琀渀攀猀猀 昀漀爀 愀 瀀愀爀琀椀挀甀氀愀爀 瀀甀爀瀀漀猀攀⸀ 夀漀甀 攀砀瀀爀攀猀猀氀礀 
// acknowledge and agree that use of this code is at your own risk.਀ 
// If you find my script useful, you can support my site in the following ways:਀⼀⼀ ㄀⸀ 嘀漀琀攀 昀漀爀 琀栀攀 猀挀爀椀瀀琀 愀琀 䠀漀琀匀挀爀椀瀀琀猀⸀挀漀洀 ⠀礀漀甀 挀愀渀 搀漀 椀琀 漀渀 洀礀 猀椀琀攀⤀ 
// 2. Link to the homepage of this script or to the homepage of my site:਀⼀⼀    栀琀琀瀀㨀⼀⼀眀眀眀⸀瀀栀瀀ⴀ搀攀瘀攀氀漀瀀洀攀渀琀⸀爀甀⼀樀愀瘀愀猀挀爀椀瀀琀猀⼀猀洀愀爀琀ⴀ昀漀爀洀猀⸀瀀栀瀀 
//    http://www.php-development.ru/਀⼀⼀    夀漀甀 眀椀氀氀 最攀琀 㔀　─ 挀漀洀洀椀猀猀椀漀渀 漀渀 愀氀氀 漀爀搀攀爀猀 洀愀搀攀 戀礀 礀漀甀爀 爀攀昀攀爀爀愀氀猀⸀ 
//    More information can be found here:਀⼀⼀    栀琀琀瀀㨀⼀⼀眀眀眀⸀瀀栀瀀ⴀ搀攀瘀攀氀漀瀀洀攀渀琀⸀爀甀⼀愀昀昀椀氀椀愀琀攀猀⸀瀀栀瀀 
਀ 
// ----- Popup Control ---------------------------------------------------------਀ 
function at_display(x)਀笀 
  win = window.open();਀  昀漀爀 ⠀瘀愀爀 椀 椀渀 砀⤀ 眀椀渀⸀搀漀挀甀洀攀渀琀⸀眀爀椀琀攀⠀椀⬀✀ 㴀 ✀⬀砀嬀椀崀⬀✀㰀戀爀㸀✀⤀㬀 
}਀ 
// ----- Show Aux -----਀ 
function at_show_aux(parent, child)਀笀 
  var p = document.getElementById(parent);਀  瘀愀爀 挀 㴀 搀漀挀甀洀攀渀琀⸀最攀琀䔀氀攀洀攀渀琀䈀礀䤀搀⠀挀栀椀氀搀⤀㬀 
਀  瘀愀爀 琀漀瀀  㴀 ⠀挀嬀∀愀琀开瀀漀猀椀琀椀漀渀∀崀 㴀㴀 ∀礀∀⤀ 㼀 瀀⸀漀昀昀猀攀琀䠀攀椀最栀琀⬀㈀ 㨀 　㬀 
  var left = (c["at_position"] == "x") ? p.offsetWidth +2 : 0;਀ 
  for (; p; p = p.offsetParent)਀  笀 
    top  += p.offsetTop;਀    氀攀昀琀 ⬀㴀 瀀⸀漀昀昀猀攀琀䰀攀昀琀㬀 
  }਀ 
  c.style.position   = "absolute";਀  挀⸀猀琀礀氀攀⸀琀漀瀀        㴀 琀漀瀀 ⬀✀瀀砀✀㬀 
  c.style.left       = left+'px';਀  挀⸀猀琀礀氀攀⸀瘀椀猀椀戀椀氀椀琀礀 㴀 ∀瘀椀猀椀戀氀攀∀㬀 
}਀ 
// ----- Show -----਀ 
function at_show()਀笀 
  p = document.getElementById(this["at_parent"]);਀  挀 㴀 搀漀挀甀洀攀渀琀⸀最攀琀䔀氀攀洀攀渀琀䈀礀䤀搀⠀琀栀椀猀嬀∀愀琀开挀栀椀氀搀∀ 崀⤀㬀 
਀  愀琀开猀栀漀眀开愀甀砀⠀瀀⸀椀搀Ⰰ 挀⸀椀搀⤀㬀 
਀  挀氀攀愀爀吀椀洀攀漀甀琀⠀挀嬀∀愀琀开琀椀洀攀漀甀琀∀崀⤀㬀 
}਀ 
// ----- Hide -----਀ 
function at_hide()਀笀 
  c = document.getElementById(this["at_child"]);਀ 
  c["at_timeout"] = setTimeout("document.getElementById('"+c.id+"').style.visibility = 'hidden'", 333);਀紀 
਀⼀⼀ ⴀⴀⴀⴀⴀ 䌀氀椀挀欀 ⴀⴀⴀⴀⴀ 
਀昀甀渀挀琀椀漀渀 愀琀开挀氀椀挀欀⠀⤀ 
{਀  瀀 㴀 搀漀挀甀洀攀渀琀⸀最攀琀䔀氀攀洀攀渀琀䈀礀䤀搀⠀琀栀椀猀嬀∀愀琀开瀀愀爀攀渀琀∀崀⤀㬀 
  c = document.getElementById(this["at_child" ]);਀ 
  if (c.style.visibility != "visible") at_show_aux(p.id, c.id);਀  攀氀猀攀 挀⸀猀琀礀氀攀⸀瘀椀猀椀戀椀氀椀琀礀 㴀 ∀栀椀搀搀攀渀∀㬀 
਀  爀攀琀甀爀渀 昀愀氀猀攀㬀 
}਀ 
// ----- Attach -----਀ 
// PARAMETERS:਀⼀⼀ 瀀愀爀攀渀琀   ⴀ 椀搀 漀昀 瘀椀猀椀戀氀攀 栀琀洀氀 攀氀攀洀攀渀琀 
// child    - id of invisible html element that will be dropdowned਀⼀⼀ 猀栀漀眀琀礀瀀攀 ⴀ ∀挀氀椀挀欀∀ 㴀 礀漀甀 猀栀漀甀氀搀 挀氀椀挀欀 琀栀攀 瀀愀爀攀渀琀 琀漀 猀栀漀眀⼀栀椀搀攀 琀栀攀 挀栀椀氀搀 
//            "hover" = you should place the mouse over the parent to show਀⼀⼀                      琀栀攀 挀栀椀氀搀 
// position - "x" = the child is displayed to the right of the parent਀⼀⼀            ∀礀∀ 㴀 琀栀攀 挀栀椀氀搀 椀猀 搀椀猀瀀氀愀礀攀搀 戀攀氀漀眀 琀栀攀 瀀愀爀攀渀琀 
// cursor   - Omit to use default cursor or check any CSS manual for possible਀⼀⼀            瘀愀氀甀攀猀 漀昀 琀栀椀猀 昀椀攀氀搀 
਀昀甀渀挀琀椀漀渀 愀琀开愀琀琀愀挀栀⠀瀀愀爀攀渀琀Ⰰ 挀栀椀氀搀Ⰰ 猀栀漀眀琀礀瀀攀Ⰰ 瀀漀猀椀琀椀漀渀Ⰰ 挀甀爀猀漀爀⤀ 
{਀  瀀 㴀 搀漀挀甀洀攀渀琀⸀最攀琀䔀氀攀洀攀渀琀䈀礀䤀搀⠀瀀愀爀攀渀琀⤀㬀 
  c = document.getElementById(child);਀ 
  p["at_parent"]     = p.id;਀  挀嬀∀愀琀开瀀愀爀攀渀琀∀崀     㴀 瀀⸀椀搀㬀 
  p["at_child"]      = c.id;਀  挀嬀∀愀琀开挀栀椀氀搀∀崀      㴀 挀⸀椀搀㬀 
  p["at_position"]   = position;਀  挀嬀∀愀琀开瀀漀猀椀琀椀漀渀∀崀   㴀 瀀漀猀椀琀椀漀渀㬀 
਀  挀⸀猀琀礀氀攀⸀瀀漀猀椀琀椀漀渀   㴀 ∀愀戀猀漀氀甀琀攀∀㬀 
  c.style.visibility = "hidden";਀ 
  if (cursor != undefined) p.style.cursor = cursor;਀ 
  switch (showtype)਀  笀 
    case "click":਀      瀀⸀漀渀挀氀椀挀欀     㴀 愀琀开挀氀椀挀欀㬀 
      p.onmouseout  = at_hide;਀      挀⸀漀渀洀漀甀猀攀漀瘀攀爀 㴀 愀琀开猀栀漀眀㬀 
      c.onmouseout  = at_hide;਀      戀爀攀愀欀㬀 
    case "hover":਀      瀀⸀漀渀洀漀甀猀攀漀瘀攀爀 㴀 愀琀开猀栀漀眀㬀 
      p.onmouseout  = at_hide;਀      挀⸀漀渀洀漀甀猀攀漀瘀攀爀 㴀 愀琀开猀栀漀眀㬀 
      c.onmouseout  = at_hide;਀      戀爀攀愀欀㬀 
  }਀紀 
