window.onerror = null;
var uaok=false;
if (typeof(decodeURI)=="function") {
	uaok=true;
	document.write('<scri'+'pt type="text/javascript" src="http://maps.google.com/maps?file=api&amp;v=2&amp;key=ABQIAAAAPwdJGh5iCooj2UtUPuQgvxTV2uM9vHnFs3kYw0pIOwHUzi3KcRSbrhEVgJX6Mv0mVtEsaM7Xr0AEPw"></scr'+'ipt>');
}

var imgrecruit = new Array();
imgrecruit[0] = new Image();
imgrecruit[0].src="images/pht5_1_1.jpg";
imgrecruit[1] = new Image();
imgrecruit[1].src="images/pht5_1_2.jpg";
imgrecruit[2] = new Image();
imgrecruit[2].src="images/pht5_1_3.jpg";

function chgtop() {
	topNO = parseInt(Math.random() * imgrecruit.length, 10) ;
	if (topNO > imgrecruit.length ) { topNO = 0; }
	document.images["TOPimg"].src = imgrecruit[topNO].src;
}

function useajax(_no){
  if(!uaok||!GBrowserIsCompatible()){
    alert("お客様のウェブブラウザは当サイトで使用している技術を完全にサポートしておりません。\n最新のウェブブラウザでご覧ください。");
    return;
  }
  if(_no == "MAP"){
    hidePopup();
    hideClock();
    StartGmap();
    load();
  }else{
    hidePopup();
    hideClock();
    StartEnquete();
  }
}

function setMove(){
	dmy = document.getElementById("btm");
	pos = getObjPos(dmy);
	limity = pos[1] + dmy.offsetHeight - 440;
	limitenqy = pos[1] + dmy.offsetHeight;
	if (is_safari10) {
		window.setInterval("onScrollHandler(evt)", 500);
	} else {
		if (window.addEventListener) {
			window.addEventListener('scroll', onScrollHandler, false);
		} else if (window.attachEvent) {
			window.attachEvent('onscroll', onScrollHandler);
		}
	}
	var obj = document.getElementById("thenq");
	if (obj != null) {
		if (obj.addEventListener) {
			obj.addEventListener("mousedown", dragEnqStart, false);
			obj.addEventListener("mouseup", dragEnqEnd, false);
			obj.addEventListener("mousemove", dragEnqDlg, false);
			window.addEventListener("mouseup", dragEnqEnd, false);
			window.addEventListener("mousemove", dragEnqDlg, false);
		} else if (obj.attachEvent) {
			obj.attachEvent("onmousedown", dragEnqStart);
			obj.attachEvent("onmouseup", dragEnqEnd);
			obj.attachEvent("onmousemove", dragEnqDlg);
			document.attachEvent("onmouseup", dragEnqEnd);
			document.attachEvent("onmousemove", dragEnqDlg);
		}
	}
	var obj = document.getElementById("gmap");
	if(is_ie){
		obj.style.width = "724px";
	}
	//ツールチップの設定
	enableTooltips("tip");
}

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.01
  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 && d.getElementById) x=d.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];}
}

var nWidth = 720;
var nHeight = 405;
var zoomsize = 5;
var route = 1;
function StartGmap() {
	document.body.style.backgroundImage = 'url(images/bg_black.jpg)';
	var objTHMap = document.getElementById('thmap');
	var arrayPageSize = getPageSize();
	var arrayPageScroll = getPageScroll();
	var gmapTop = arrayPageScroll[1] + ((arrayPageSize[3] - 35 - nHeight) / 2) - 20;
	var gmapLeft = ((arrayPageSize[0] - nWidth) / 2);
	
	objTHMap.style.top = (gmapTop < 0) ? "0px" : gmapTop + "px";
	objTHMap.style.left = (gmapLeft < 0) ? "0px" : gmapLeft + "px";

	objTHMap.style.visibility="visible";

	zoomsize = 5;
	route = 1;
}

function hideGmap() {
	if(document.layers) {
		document.thmap.visibility="hide";
	} else {
		var objTHMap = document.getElementById('thmap');
		objTHMap.style.visibility="hidden";
	}
	document.body.style.backgroundImage = 'url(images/bg.jpg)';
	showClock();
}

function hideClock() {
	if(document.layers) {
		document.clockflash.visibility="hide";
	} else {
		var objClock = document.getElementById('clockflash');
		objClock.style.visibility="hidden";
	}
}

function showClock() {
	if(document.layers) {
		document.clockflash.visibility="visible";
	} else {
		var objClock = document.getElementById('clockflash');
		objClock.style.visibility="visible";
	}
}

function getPageSize(){
	
	var xScroll, yScroll;
	
	if (window.innerHeight && window.scrollMaxY) {	
		xScroll = document.body.scrollWidth;
		yScroll = window.innerHeight + window.scrollMaxY;
	} else if (document.body.scrollHeight > document.body.offsetHeight){
		xScroll = document.body.scrollWidth;
		yScroll = document.body.scrollHeight;
	} else {
		xScroll = document.body.offsetWidth;
		yScroll = document.body.offsetHeight;
	}
	
	var windowWidth, windowHeight;
	if (self.innerHeight) {
		windowWidth = self.innerWidth;
		windowHeight = self.innerHeight;
	} else if (document.documentElement && document.documentElement.clientHeight) {
		windowWidth = document.documentElement.clientWidth;
		windowHeight = document.documentElement.clientHeight;
	} else if (document.body) {
		windowWidth = document.body.clientWidth;
		windowHeight = document.body.clientHeight;
	}	
	
	if(yScroll < windowHeight){
		pageHeight = windowHeight;
	} else { 
		pageHeight = yScroll;
	}

	if(xScroll < windowWidth){	
		pageWidth = windowWidth;
	} else {
		pageWidth = xScroll;
	}


	arrayPageSize = new Array(pageWidth,pageHeight,windowWidth,windowHeight) 
	return arrayPageSize;
}
function getPageScroll(){

	var yScroll;

	if (self.pageYOffset) {
		yScroll = self.pageYOffset;
	} else if (document.documentElement && document.documentElement.scrollTop){
		yScroll = document.documentElement.scrollTop;
	} else if (document.body) {
		yScroll = document.body.scrollTop;
	}

	arrayPageScroll = new Array('',yScroll) 
	return arrayPageScroll;
}
function hidePopup() {
	hideGmap();
	hide_enq();
}

//<![CDATA[
var zoomsize = 5;
var _gmap;
var route = 1;
var iflag = 1;
var rflag = 0;
var technicalhero = null;
var thcenter = null;
var thimg = new Image();
var polyline = null;
thimg.src = "./images/logo.gif";
var thmsg = "<div style='font-size: 8pt'>";
thmsg += "<table><tr><td width='100'>";
thmsg += "<img src='"+thimg.src+"' align='left'>";
thmsg += "</td><td style='font-size: 8pt'>";
thmsg += "<b>株式会社テクニカルヒーロー</b><br>";
thmsg += "〒810-0004<br>";
thmsg += "福岡市中央区渡辺通２－３－２７<br>";
thmsg += "待鳥ビル２F<br>";
thmsg += "TEL:092-712-7431 / FAX:092-712-7450";
thmsg += "</td></tr></table>";
thmsg += "</div>";

function load() {
  if (uaok&&GBrowserIsCompatible()) {
    technicalhero = new GLatLng(33.582359, 130.40367);
    thcenter = new GLatLng(33.58285036784122, 130.40361642837524);
    var gmap = new GMap2(document.getElementById("gmap"));
    gmap.addControl(new GLargeMapControl());
    gmap.addControl(new GMapTypeControl());
    gmap.setCenter(thcenter, 17, G_NORMAL_MAP);
//    gmap.setCenter(thcenter, 17, G_SATELLITE_MAP);
    GEvent.addListener(gmap, "move", function() {
      window.status = gmap.getCenter()
    });
    _gmap = gmap;
    createMarker();
	  _gmap.openInfoWindowHtml(technicalhero, thmsg);
	  GEvent.addListener(_gmap, "infowindowclose", function() {
	    iflag = 0;
	  });
//        zoomth();
  }
}
function zoommap() {
  _gmap.clearOverlays();
  route = 1;
  createMarker();
  zoomsize = 5;
  _gmap.setCenter(thcenter, zoomsize, G_NORMAL_MAP);
  zoomth();
}
function zoomth() {
  if(_gmap.isLoaded()){
    _gmap.setZoom(zoomsize);
    if(zoomsize < 16){
      setTimeout('zoomth()',1000);
    }else{
      setTimeout('gototh()',1000);
      return;
    }
    zoomsize += 2;
  }else{
    setTimeout('zoomth()',1000);
  }
}
function createMarker() {
  var icon = new GIcon();
  icon.image = "./images/point.png";
  icon.iconSize = new GSize(19, 21);
  icon.iconAnchor = new GPoint(9, 20);
  icon.infoWindowAnchor = new GPoint(9, 20);
  var marker = new GMarker(technicalhero, icon);
  _gmap.addOverlay(marker);
  GEvent.addListener(marker, "click", function() {
    marker.openInfoWindowHtml(thmsg);
    iflag = 1;
  });
}
function gototh() {
  if(route == 1){
	  polyline = new GPolyline([
	  new GLatLng(33.582046, 130.401664),
	  new GLatLng(33.581751, 130.401707),
	  new GLatLng(33.581688, 130.402758),
	  new GLatLng(33.581796, 130.403928),
	  new GLatLng(33.582314083044984, 130.40352523326874),
	  new GLatLng(33.582349835468406, 130.40360033512115)
	  ], "#FF0000", 4, 0.9);
    _gmap.setCenter(thcenter, 17);
    _gmap.addOverlay(polyline);
    if(iflag == 0){
	    _gmap.openInfoWindowHtml(technicalhero, thmsg);
	    rflag = 1;
	  }
    route = 0;
  }else{
    _gmap.removeOverlay(polyline);
    //_gmap.clearOverlays();
    if(rflag == 1){
    	_gmap.closeInfoWindow()
    	rflag = 0;
    }
    route = 1;
  }
  //createMarker();
}
//]]>



//ウィンドウ動かす
var iniclisiz;
var limity;
var limitenqy;

var is_gecko = (window.navigator.userAgent.match(/Gecko/i) != null);
var is_ie = (window.navigator.userAgent.match(/MSIE/i) != null);
var is_opera = (window.navigator.userAgent.match(/Opera/i) != null);
var is_safari = (window.navigator.userAgent.match(/Safari/i) != null);
var is_safari10 = false;
if (is_safari) {
	bld = parseInt(window.navigator.userAgent.split("/")[3], 10);
	is_safari10 = (bld < 100);
}

function getObjPos(obj) {
 if (typeof(window.pageXOffset) == "undefined") {
  // ie
  x = obj.offsetLeft;
  y = obj.offsetTop;
  p = obj.offsetParent;
  while (p != null) {
   x += p.offsetLeft;
   y += p.offsetTop;
   p = p.offsetParent;
  }
  return new Array(x, y);
 } else {
  // ns, ff
  x = obj.offsetLeft;
  y = obj.offsetTop;
  p = obj.offsetParent;
  while (p != null) {
   x += p.offsetLeft;
   y += p.offsetTop;
   p = p.offsetParent;
  }
  return new Array(x, y);
 }
}

function getScrollPos() {
 if (typeof(window.pageYOffset) == "undefined") {
  // ie
  h = document.getElementsByTagName("html");
  x = document.body.scrollLeft > 0 ? document.body.scrollLeft : h[0].scrollLeft;
  y = document.body.scrollTop > 0 ? document.body.scrollTop : h[0].scrollTop;
  return new Array(x, y);
 } else {
  return new Array(window.pageXOffset, window.pageYOffset);
 }
}

function getScrollSize() {
 if (typeof(window.pageYOffset) == "undefined") {
  // ie
  x = document.body.scrollWidth;
  y = document.body.scrollHeight;
  return new Array(x, y);
 } else {
  x = document.body.scrollWidth;
  y = document.body.scrollHeight;
  return new Array(x, y);
 }
}

function getClientSize() {
	h = document.getElementsByTagName("html");
	if (is_safari) {
		return new Array(window.innerWidth, window.innerHeight);
	} else if (is_opera) {
		return new Array(document.body.clientWidth, document.body.clientHeight);
	} else if (is_gecko) {
		// ie, gecko その他
		wi = document.body.clientWidth;
		he = document.body.clientHeight;
		return new Array(wi, he);
	} else{
		// ie, gecko その他
		wi = document.documentElement.clientWidth > 0 ?document.documentElement.clientWidth : document.body.clientWidth;
		he = document.documentElement.clientHeight > 0 ? document.documentElement.clientHeight : document.body.clientHeight;
		return new Array(wi, he);
	}
}

function recalcLayoutSSBar() {
	var o = document.getElementById("thmap");
	if (o != null) {
		scrpos = getScrollPos();
		clisiz = getClientSize();
		y = scrpos[1]+clisiz[1]-o.offsetHeight;
		if (y > limity) y = limity;
		o.style.top = y+"px";
		o.style.width = ((clisiz[0] >= 720) ? clisiz[0] : 720)+"px";
//		openShim(o);
	}
}

function recalcLayoutSSDlg() {
	var o = document.getElementById("thmap");
	if (o != null) {
		scrpos = getScrollPos();
		clisiz = getClientSize();
		o.style.left = parseInt((scrpos[0]+(clisiz[0]-o.offsetWidth)/2), 10)+"px";
		y = parseInt(scrpos[1]+(clisiz[1]-o.offsetHeight)/2, 10);
//alert('scrpos:'+scrpos[1]+' / clisiz:'+clisiz[1]+' / height:'+o.offsetHeight);
		if (y < 0) y = 0;
		if (y > limity) y = limity;
		o.style.top = y+"px";
//		openShim(o);
	}
}


function onScrollHandler(e) {
//	recalcLayoutSSBar();
	recalcLayoutSSDlg();
}

window.onresize = function(e) {
//	recalcLayoutSSBar();
	recalcLayoutSSDlg();
}


function openShim(obj)
{
	if (is_ie) {
    if (obj==null) return;
    var shim = getShim(obj);
    if (shim==null) shim = createShim(obj,getShimId(obj));
    
    //Change obj zIndex so shim can work with it
    obj.style.zIndex = 100;
    var width = obj.offsetWidth;
    var height = obj.offsetHeight;
    
    shim.style.width = width+"px";
    shim.style.height = height+"px";
    shim.style.top = obj.style.top;
    shim.style.left = obj.style.left;
    shim.style.zIndex = obj.style.zIndex - 1;
    shim.style.position = "absolute";
    shim.style.display = "block";
  }
}


function closeShim(obj)
{
	if (is_ie) {
    if (obj==null) return;
    var shim = getShim(obj);
    if (shim!=null) shim.style.display = "none";
  }
}

//Creates a new shim for the obj
function createShim(obj)
{
    if (obj==null) return null;

    var shim = document.createElement("<iframe scrolling='no' frameborder='0'"+
                                      "style='position:absolute; top:0px;"+
                                      "left:0px; display:none'></iframe>"); 
    shim.name = getShimId(obj);
    shim.id = getShimId(obj);

    if (obj.offsetParent==null || obj.offsetParent.id=="") 
    {
        window.document.body.appendChild(shim);
    }
    else 
    {
        obj.offsetParent.appendChild(shim); 
    }

    return shim;
}

//Creates an id for the shim based on the obj id
function getShimId(obj)
{
    if (obj.id==null) return "__shim";
    return "__shim"+obj.id;
}

//Returns the shim for a specific obj
function getShim(obj)
{
    return document.getElementById(getShimId(obj));
}

/* Smooth scrolling
   Changes links that link to other parts of this page to scroll
   smoothly to those links rather than jump to them directly, which
   can be a little disorienting.
   
   sil, http://www.kryogenix.org/
   
   v1.0 2003-11-11
   v1.1 2005-06-16 wrap it up in an object
*/

var ss = {
  fixAllLinks: function() {
    // Get a list of all links in the page
    var allLinks = document.getElementsByTagName('a');
    // Walk through the list
    for (var i=0;i<allLinks.length;i++) {
      var lnk = allLinks[i];
      if ((lnk.href && lnk.href.indexOf('#') != -1) && 
          ( (lnk.pathname == location.pathname) ||
	    ('/'+lnk.pathname == location.pathname) ) && 
          (lnk.search == location.search)) {
        // If the link is internal to the page (begins in #)
        // then attach the smoothScroll function as an onclick
        // event handler
        ss.addEvent(lnk,'click',ss.smoothScroll);
      }
    }
    // Get a list of all links in the page
    var allLinks = document.getElementsByTagName('area');
    // Walk through the list
    for (var i=0;i<allLinks.length;i++) {
      var lnk = allLinks[i];
      if ((lnk.href && lnk.href.indexOf('#') != -1) && 
          ( (lnk.pathname == location.pathname) ||
	    ('/'+lnk.pathname == location.pathname) ) && 
          (lnk.search == location.search)) {
        // If the link is internal to the page (begins in #)
        // then attach the smoothScroll function as an onclick
        // event handler
        ss.addEvent(lnk,'click',ss.smoothScroll);
      }
    }
  },

  smoothScroll: function(e) {
    // This is an event handler; get the clicked on element,
    // in a cross-browser fashion
    if (window.event) {
      target = window.event.srcElement;
    } else if (e) {
      target = e.target;
    } else return;

    // Make sure that the target is an element, not a text node
    // within an element
    if ((target.nodeName.toLowerCase() != 'a') && (target.nodeName.toLowerCase() != 'area')) {
      target = target.parentNode;
    }
  
    // Paranoia; check this is an A tag
    if ((target.nodeName.toLowerCase() != 'a') && (target.nodeName.toLowerCase() != 'area')) return;
  
    // Find the <a name> tag corresponding to this href
    // First strip off the hash (first character)
    anchor = target.hash.substr(1);
    // Now loop all A tags until we find one with that name
    var allLinks = document.getElementsByTagName('a');
    var destinationLink = null;
    for (var i=0;i<allLinks.length;i++) {
      var lnk = allLinks[i];
      if (lnk.name && (lnk.name == anchor)) {
        destinationLink = lnk;
        break;
      }
    }
    if(destinationLink == null){
      var allLinks = document.getElementsByTagName('area');
	    for (var i=0;i<allLinks.length;i++) {
	      var lnk = allLinks[i];
	      if (lnk.name && (lnk.name == anchor)) {
	        destinationLink = lnk;
	        break;
	      }
	    }
	  }

  
    // If we didn't find a destination, give up and let the browser do
    // its thing
    if (!destinationLink) return true;
  
    // Find the destination's position
    var destx = destinationLink.offsetLeft; 
    var desty = destinationLink.offsetTop;
    var thisNode = destinationLink;
    while (thisNode.offsetParent && 
          (thisNode.offsetParent != document.body)) {
      thisNode = thisNode.offsetParent;
      destx += thisNode.offsetLeft;
      desty += thisNode.offsetTop;
    }
  
    // Stop any current scrolling
    clearInterval(ss.INTERVAL);
  
    cypos = ss.getCurrentYPos();
  
    ss_stepsize = parseInt((desty-cypos)/ss.STEPS);
    ss.INTERVAL = setInterval('ss.scrollWindow('+ss_stepsize+','+desty+',"'+anchor+'")',ss.INTTIME);
  
    // And stop the actual click happening
    if (window.event) {
      window.event.cancelBubble = true;
      window.event.returnValue = false;
    }
    if (e && e.preventDefault && e.stopPropagation) {
      e.preventDefault();
      e.stopPropagation();
    }
  },

  scrollWindow: function(scramount,dest,anchor) {
    wascypos = ss.getCurrentYPos();
    isAbove = (wascypos < dest);
    moveamount = (dest - wascypos) / ss.DOWN;
    if(moveamount < 0){
      if(moveamount > -5){
      	moveamount = -4;
      }
    }else if(moveamount < 5){
      moveamount = 4;
    }
    var moveto = Math.round(wascypos + moveamount);
window.status = wascypos + moveamount;
//    window.scrollTo(0,wascypos + scramount);
    window.scrollTo(0,wascypos + moveamount);
    iscypos = ss.getCurrentYPos();
    isAboveNow = (iscypos < dest);
    if ((isAbove != isAboveNow) || (wascypos == iscypos) || (iscypos == 0)) {
      // if we've just scrolled past the destination, or
      // we haven't moved from the last scroll (i.e., we're at the
      // bottom of the page) then scroll exactly to the link
      window.scrollTo(0,dest);
      // cancel the repeating timer
      clearInterval(ss.INTERVAL);
      // and jump to the link directly so the URL's right
      location.hash = anchor;
    }
  },

  getCurrentYPos: function() {
    if (document.body && document.body.scrollTop)
      return document.body.scrollTop;
    if (document.documentElement && document.documentElement.scrollTop)
      return document.documentElement.scrollTop;
    if (window.pageYOffset)
      return window.pageYOffset;
    return 0;
  },

  addEvent: function(elm, evType, fn, useCapture) {
    // addEvent and removeEvent
    // cross-browser event handling for IE5+,  NS6 and Mozilla
    // By Scott Andrew
    if (elm.addEventListener){
      elm.addEventListener(evType, fn, useCapture);
      return true;
    } else if (elm.attachEvent){
      var r = elm.attachEvent("on"+evType, fn);
      return r;
    } else {
      alert("Handler could not be removed");
    }
  } 
}

ss.STEPS = 24;
ss.DOWN = 6;
ss.INTTIME = 10;
ss.addEvent(window,"load",ss.fixAllLinks);
//スクロール - ここまで


//吹き出し - ここから
/*script per i bubble tooltips - http://pro.html.it */

function enableTooltips(id){
var links,i,h;
if(!document.getElementById || !document.getElementsByTagName) return;
AddCss();
h=document.createElement("span");
h.id="btc";
h.setAttribute("id","btc");
h.style.position="absolute";
document.getElementsByTagName("body")[0].appendChild(h);
if(id==null) links=document.getElementsByTagName("area");
else links=document.getElementById(id).getElementsByTagName("area");
for(i=0;i<links.length;i++){
    Prepare(links[i]);
    }
}

function Prepare(el){
var tooltip,t,b,s,l;
var arr_t = "";
var tx_i = 0;

//alt文字列の取得[解説]
t=el.getAttribute("alt");
if(t==null || t.length==0) t="link:";
el.removeAttribute("alt");
//t=t.replace(/ /,"<br>")
//スペースを改行文字列にする
arr_t = t.split(" ");
//name文字列の取得[会社名]
l=el.getAttribute("name");
//if(l.length>30) l=l.substr(0,27)+"...";
if(l==null || l.length==0) l="";
//吹き出しの作成
tooltip=CreateEl("span","tooltip");
s=CreateEl("b","top");
s.appendChild(document.createTextNode(l));
tooltip.appendChild(s);
b=CreateEl("span","bottom");
//b.appendChild(document.createTextNode(t));
for(var tx in arr_t){
	if(tx_i != 0){
		b.appendChild(document.createElement("br"));
	}
	b.appendChild(document.createTextNode(arr_t[tx]));
	tx_i++;
}
tooltip.appendChild(b);
setOpacity(tooltip);
el.tooltip=tooltip;
el.onmouseover=showTooltip;
el.onmouseout=hideTooltip;
el.onmousemove=Locate;
}

function showTooltip(e){
document.getElementById("btc").appendChild(this.tooltip);
Locate(e);
}

function hideTooltip(e){
var d=document.getElementById("btc");
if(d.childNodes.length>0) d.removeChild(d.firstChild);
}

function setOpacity(el){
el.style.filter="alpha(opacity:95)";
el.style.KHTMLOpacity="0.95";
el.style.MozOpacity="0.95";
el.style.opacity="0.95";
}

function CreateEl(t,c){
var x=document.createElement(t);
x.className=c;
x.style.display="block";
return(x);
}

function AddCss(){
var l=CreateEl("link");
l.setAttribute("type","text/css");
l.setAttribute("rel","stylesheet");
l.setAttribute("href","bt.css");
l.setAttribute("media","screen");
document.getElementsByTagName("head")[0].appendChild(l);
}

function Locate(e){
var posx=0,posy=0;
if(e==null) e=window.event;
if(e.pageX || e.pageY){
    posx=e.pageX; posy=e.pageY;
    }
else if(e.clientX || e.clientY){
    if(document.documentElement.scrollTop){
        posx=e.clientX+document.documentElement.scrollLeft;
        posy=e.clientY+document.documentElement.scrollTop;
        }
    else{
        posx=e.clientX+document.body.scrollLeft;
        posy=e.clientY+document.body.scrollTop;
        }
    }
document.getElementById("btc").style.top=(posy+10)+"px";
document.getElementById("btc").style.left=(posx-20)+"px";
}
//吹き出し - ここまで

//エフェクト - ここから
function _Effect_Obj( obj, ext ) {
obj.style.backgroundImage = "url('"+ext+"')"
}
function Effect_Out(obj ,no) {
	_Effect_Obj( obj, "images/effect"+no+"_out.gif" );
}
function Effect_Over(obj ,no) {
	_Effect_Obj( obj, "images/effect"+no+"_over.gif" );
}
//エフェクト - ここまで
