function gebi(id){
	return document.getElementById(id)
}


  function artifactAlt(obj, evnt, show) {
    var div = gebi(obj.getAttribute('div_id'));
    if (!div) return;
    var act1 = obj.getAttribute('act1');
    var act2 = obj.getAttribute('act2');
    if (show == 2) {
      document.onmousemove=function(e) {artifactAlt(obj, e||event, 1)} 
      div.style.display = 'block';
      if (act1 || act2) {
        if (obj.tagName == 'IMAGE') {
          obj.src = ("images/itemact-"+ act1) + (act2 +".gif")
        } else {
          obj.style.backgroundImage = 'url(' + ("images/itemact-"+ act1) + (act2 +".gif") + ')'
        }
      }
    }
    if (!show) {
      if (act1 || act2) {
        if (obj.tagName == 'IMAGE') {
          obj.src = "images/d.gif"
        } else {
          obj.style.backgroundImage = 'url(' + "/img/d.gif" + ')'
        }
      }
      div.style.display = 'none';
      document.onmousemove=function(){}
      return;
    }
    
    var ex = evnt.clientX + document.body.scrollLeft;
    var ey = evnt.clientY + document.body.scrollTop;

	if (act1 || act2) {
		obj.style.cursor = 'hand'
		var coord = getCoords(obj)
		var cont = document.getElementById("item_list")
		var rel_x = (ex + cont.scrollLeft - coord.l)
	}
    var x = evnt.clientX + div.offsetWidth > document.body.clientWidth - 7 ? ex - div.offsetWidth - 10 : ex + 10;
    var y = evnt.clientY + div.offsetHeight > document.body.clientHeight - 7 ? ey - div.offsetHeight - 10 : ey + 10;
 
    if (x < 0 ) {
      x = ex - div.offsetWidth/2
    }
    if (x < 7 ) {
      x = 7
    }
    if (x > document.body.clientWidth - div.offsetWidth - 7) {
      x= document.body.clientWidth - div.offsetWidth - 7
    }
    div.style.left = x + "px";
    div.style.top = y + "px";
   }
