function changeimg()
{
n=Math.random();
n2=Math.floor(n*100); // x: 数値
n2 %=5;
document.piko.src="images/chara/" + n2 + ".gif";
document.write =(n2);
}

function sendsub()
{
	document.googl.submit();
}

//――――――――――――――――――――――――――――――――――――――
// 作成者 るび〜/ACCESS R http://www5e.biglobe.ne.jp/~access_r/
//――――――――――――――――――――――――――――――――――――――
function ImageChange(){
	if(document.all){
			//縦幅のウィンドウサイズより120ピクセル小さい値を取得
		document.all("maintbl").style.height = document.body.clientHeight - 120;
	}else if(document.getElementById){
                        //縦幅のウィンドウサイズより120ピクセル小さい値を取得
		document.getElementById("maintbl").style.height = window.innerHeight - 120;
	}

window.onresize = ImageChange;
}
//――――――――――――――――――――――――――――――――――――――
// showlayer
//――――――――――――――――――――――――――――――――――――――
	function showlayer(e,idName){
		if (document.all){
			curX	=	event.clientX;
			curY	=	event.clientY;
		}
		else{
			curX	=	e.pageX;
			curY	=	e.pageY;
		}

		layerX	=	curX-455;
		layerY	=	curY+20;

		if (document.all){
			document.all(idName).style.left	=	layerX;
			document.all(idName).style.top		=	layerY;
			document.all(idName).style.visibility	=	"visible";
		}
		else if (document.getElementById){
			document.getElementById(idName).style.left	=	layerX;
			document.getElementById(idName).style.top	=	layerY;
			document.getElementById(idName).style.visibility	=	"visible";
		}
		else if (document.layers){
			document.layers[idName].left	=	layerX;
			document.layers[idName].top	=	layerY;
			document.layers[idName].visibility	=	"visible";
		}
	}

	function closelayer(idName){
		if (document.getElementById){
			document.getElementById(idName).style.visibility	=	"hidden";
		}
		else if (document.all){
			document.all(idName).style.visibility	=	"hidden";
		}
		else if (document.layers){
			document.layers[idName].visibility	=	"hidden";
		}
	}




//――――――――――――――――――――――――――――――――――――――
// showlayer2
//――――――――――――――――――――――――――――――――――――――
	function showlayer2(e,idName){

		if (document.all){
			document.all(idName).style.left	=	0;
			document.all(idName).style.top		=	0;
			document.all(idName).style.visibility	=	"visible";
		}
		else if (document.getElementById){
			document.getElementById(idName).style.left	=	0;
			document.getElementById(idName).style.top	=	0;
			document.getElementById(idName).style.visibility	=	"visible";
		}
		else if (document.layers){
			document.layers[idName].left	=	0;
			document.layers[idName].top	=	0;
			document.layers[idName].visibility	=	"visible";
		}
	}

	function closelayer2(idName){
		if (document.getElementById){
			document.getElementById(idName).style.visibility	=	"hidden";
		}
		else if (document.all){
			document.all(idName).style.visibility	=	"hidden";
		}
		else if (document.layers){
			document.layers[idName].visibility	=	"hidden";
		}
	}
function showtext(){
//	str = navigator.appName.toUpperCase();
//	alert(str.index0f);
	if(navigator.appName.indexOf("Microsoft") > -1){
//	if (str.index0f("EXPLORER") >= 0)
		showlayer2(event,'text1') ;
		closelayer2('image1');
	}
	else if(navigator.appName.indexOf("Netscape") > -1){
//	else if (str.index0f("Netscape") >= 0){
		location.href="index_t.html";
	}
	else{
		location.href='index_t.html';
	}
	
//	}
}
function showimage(){
	showlayer2(event,'image1') ;
	closelayer2('text1');
}

function updateget(){
myModify = document.lastModified;
myD = new Date(myModify);
myYear = myD.getYear();
myYear4 = (myYear < 2000) ? myYear+1900 : myYear;
myMonth = myD.getMonth() + 1; 
myDate = myD.getDate(); 
myStr = "Last updated: " + myYear4 + "." + myMonth + "." + myDate;
document.write( myStr ); 
}
function updateget2(){
myModify = document.lastModified;
myD = new Date(myModify);
myYear = myD.getYear();
myYear4 = (myYear < 2000) ? myYear+1900 : myYear;
myMonth = myD.getMonth() + 1; 
myDate = myD.getDate(); 
myStr = myYear4 + "." + myMonth + "." + myDate;
document.write( myStr ); 
}



function closewin()
{ window.close(); }

function print_out() {
   /* print() が使えるブラウザかどうかを判断 */
   if (navigator.userAgent.match(/msie (\d)/i))
      v = (eval(RegExp.$1) >= 5) ? 1 : 0;
   else if (self.innerWidth)
      v = (eval(navigator.appVersion.charAt(0)) >= 4) ? 1 : 0;
   else v = 0;

   /* print() が使えるブラウザなら印刷を実行 */
   if (v) self.print();
   else alert('we can not print ');
}
//-->
<!--HPB_SCRIPT_ROV_50
//
//  Licensed Materials - Property of IBM
//  5724I83
//  (C) Copyright IBM Corp. 1995, 2004 All Rights Reserved.
//

// HpbImgPreload:
//
function HpbImgPreload()
{
  var appVer=parseInt(navigator.appVersion);
  var isNC=false,isN6=false,isIE=false;
  if (document.all && appVer >= 4) isIE=true; else
    if (document.getElementById && appVer > 4) isN6=true; else
      if (document.layers && appVer >= 4) isNC=true;
  if (isNC||isN6||isIE)
  {
    if (document.images)
    {
      var imgName = HpbImgPreload.arguments[0];
      var cnt;
      swImg[imgName] = new Array;
      for (cnt = 1; cnt < HpbImgPreload.arguments.length; cnt++)
      {
        swImg[imgName][HpbImgPreload.arguments[cnt]] = new Image();
        swImg[imgName][HpbImgPreload.arguments[cnt]].src = HpbImgPreload.arguments[cnt];
      }
    }
  }
}
// HpbImgFind:
//
function HpbImgFind(doc, imgName)
{
  for (var i=0; i < doc.layers.length; i++)
  {
    var img = doc.layers[i].document.images[imgName];
    if (!img) img = HpbImgFind(doc.layers[i], imgName);
    if (img) return img;
  }
  return null;
}
// HpbImgSwap:
//
function HpbImgSwap(imgName, imgSrc)
{
  var appVer=parseInt(navigator.appVersion);
  var isNC=false,isN6=false,isIE=false;
  if (document.all && appVer >= 4) isIE=true; else
    if (document.getElementById && appVer > 4) isN6=true; else
      if (document.layers && appVer >= 4) isNC=true;
  if (isNC||isN6||isIE)
  {
    if (document.images)
    {
      var img = document.images[imgName];
      if (!img) img = HpbImgFind(document, imgName);
      if (img) img.src = imgSrc;
    }
  }
}
var swImg; swImg=new Array;
//-->
<!--HPB_SCRIPT_PLD_50
HpbImgPreload('_HPB_ROLLOVER1', 'images/m1.gif', 'images/m12.gif');
HpbImgPreload('_HPB_ROLLOVER2', 'images/m2.gif', 'images/m22.gif');
HpbImgPreload('_HPB_ROLLOVER3', 'images/m3.gif', 'images/m32.gif');
HpbImgPreload('_HPB_ROLLOVER4', 'images/m4.gif', 'images/m42.gif');
HpbImgPreload('_HPB_ROLLOVER5', 'images/m5.gif', 'images/m52.gif');
HpbImgPreload('_HPB_ROLLOVER6', 'images/m6.gif', 'images/m62.gif');
//-->

<!--staff roll
var wx=new Array(),wy=new Array(),ex=new Array(),ey=new Array()
var spd=new Array(),step=new Array(),stepX=new Array(),stepY=new Array()
var mvFlag=new Array(),slideID=new Array(),count=new Array()

function slideLayer(layName,startX,startY,endX,endY,speed,stpx){
 if(!mvFlag[layName]){
clearTimeout(slideID[layName])
count[layName]=0
var ofX=(endX-startX)
var ofY=(endY-startY)
step[layName]=
Math.max(Math.abs(ofX),Math.abs(ofY))/stpx
stepX[layName]=ofX/step[layName]
stepY[layName]=ofY/step[layName]
wx[layName]=startX
wy[layName]=startY
ex[layName]=endX
ey[layName]=endY
spd[layName]=speed
mvFlag[layName]=true
 }
 if(mvFlag[layName]&&(count[layName]<=step[layName]-1)){
count[layName]++
wx[layName]+=stepX[layName]
wy[layName]+=stepY[layName]
clearTimeout(slideID[layName])
slideID[layName]=
setTimeout('slideLayer("'+layName+'")',spd[layName])
 }else{
wx[layName]=ex[layName]
wy[layName]=ey[layName]
clearTimeout(slideID[layName]);mvFlag[layName]=false
 }
 if(document.layers)
document.layers[layName].moveTo(wx[layName],wy[layName])
 if(document.all)document.all(layName).style.posLeft=wx[layName]
 if(document.all)document.all(layName).style.posTop=wy[layName]
}

function getInnerHeight(){
if(document.layers)var pageHeight=window.innerHeight
if(document.all)var pageHeight=document.body.clientHeight
 return pageHeight
}

window.onerror=null
function startMove(){
	showlayer2(event,'text') ;

	mvFlag['text']=false;slideLayer('text',0, getInnerHeight()+30, 0, 0, 20, 3)

}
y = 0;
move = 200;
timer = null;
motion = 10;
speed = 100;
function autoScroll() {
  if (y < move) {
    scrollTo(0, y+=motion);
    clearTimeout(timer);
    timer = setTimeout("autoScroll()", speed);
  }

}
// -->
/*flash menu*/
function RunFoo()

{

document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="770" height="50" id="MENU" align="middle">\n');

document.write('<param name="allowScriptAccess" value="sameDomain" />\n');

document.write('<param name="movie" value="menu.swf" />\n');

document.write('<param name="quality" value="high" />\n');

document.write('<param name="bgcolor" value="#ffffff" />\n');

document.write('<embed src="menu.swf" quality="high" bgcolor="#ffffff" width="770" height="50" name="menu" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />\n');

document.write('</object>\n');

}
function RunFoos()

{

document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="770" height="50" id="menus" align="middle">\n');

document.write('<param name="allowScriptAccess" value="sameDomain" />\n');

document.write('<param name="movie" value="http://yutenji.biz/menus.swf" />\n');

document.write('<param name="quality" value="high" />\n');

document.write('<param name="bgcolor" value="#ffffff" />\n');

	document.write('<embed src="http://yutenji.biz/menus.swf" quality="high" bgcolor="#ffffff" width="770" height="50" name="menus" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />\n');

document.write('</object>\n');

}

function RunFoop()

{

document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="770" height="50" id="menus" align="middle">\n');

document.write('<param name="allowScriptAccess" value="sameDomain" />\n');

document.write('<param name="movie" value="http://pcdoc.yutenji.biz/menus.swf" />\n');

document.write('<param name="quality" value="high" />\n');

document.write('<param name="bgcolor" value="#ffffff" />\n');

	document.write('<embed src="http://pcdoc.yutenji.biz/menus.swf" quality="high" bgcolor="#ffffff" width="770" height="50" name="menus" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />\n');

document.write('</object>\n');

}
function RunFoom()

{

document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="280" height="210" id="mos1" align="middle">\n');

document.write('<param name="allowScriptAccess" value="sameDomain" />\n');

document.write('<param name="movie" value="http://yutenji.biz/curriculum/images/swf/mos2.swf" />\n');

document.write('<param name="quality" value="high" />\n');

document.write('<param name="bgcolor" value="#ffffff" />\n');

document.write('<embed src="http://yutenji.biz/curriculum/images/swf/mos2.swf" quality="high" bgcolor="#ffffff" width="280" height="210" name="mos1" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />\n');

document.write('</object>\n');

}

function tostrad()
	{
	location.href = "http://yutenji.biz/curriculum/courses/mos1.html";
}
function topdcast()
	{
	location.href = "http://warapaso.yutenji.biz/podcast/2008/01/im/pcast094view.html";
}
function toyuyu()
	{
	location.href = "http://yuyuc.yutenji.biz/ad/yuyucad2.html";
}
function tocalendar()
	{
	location.href = "http://yutenji.biz/calendar.html";
}
function tofree()
	{
	location.href = "http://yutenji.biz/curriculum/free/freead.html";
}
function tocollege()
	{
	location.href = "http://yutenji.biz/college/college.html";
}
function topuzzle()
	{
	location.href = "http://yutenji.biz/classes/games/picpuz/picpuzad.html";
}
function toshoshinsha()
	{
	location.href = "http://yutenji.biz/curriculum/courses/strad.html";
}
function tohint()
	{
	location.href = "http://yutenji.biz/recipe/hint.html";
}
function tonew()
	{
	location.href = "http://yutenji.biz/new.html";
}
function bnChange()
{
n=Math.random();
n2=Math.floor(n*100); // x: 数値
n2 %=2;
document.bn1.src="images/bg/" + n2 + ".jpg";
document.write =(n2);
}
function analysis()
{
document.write("<img src='http://yutenji.biz/cgi/acc/acclog.cgi?");
document.write("referrer="+document.referrer+"&");
document.write("width="+screen.width+"&");
document.write("height="+screen.height+"&");
document.write("color="+screen.colorDepth+"'>");
}
function infoswf()
{

document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="610" height="330" id="culture">\n');

document.write('<param name="allowScriptAccess" value="sameDomain">\n');

document.write('<param name="movie" value="culture.swf">\n');

document.write('<param name="menu" value="false">\n');
	
document.write('<param name="quality" value="high">\n');

document.write('<param name="bgcolor" value="#ffffff">\n');

document.write('<embed src="culture.swf" menu="false" quality="high" bgcolor="#ffffff" width="610" height="330" name="culture" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer">\n');

document.write('</object>\n');

}
function adswf()
{

document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="160" height="180" id="pcast071topad" align="middle">\n');

document.write('<param name="allowScriptAccess" value="sameDomain">\n');

document.write('<param name="movie" value="images/swf/pcast071topad.swf">\n');

document.write('<param name="menu" value="false">\n');
	
document.write('<param name="quality" value="high">\n');

document.write('<param name="bgcolor" value="#ffe1a4">\n');

document.write('<embed src="images/swf/pcast071topad.swf" quality="high" bgcolor="#ffe1a4" width="160" height="180" name="pcast071topad" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer">\n');

document.write('</object>\n');

}

function HpbImgPreload()
{
  var appVer=parseInt(navigator.appVersion);
  var isNC=false,isN6=false,isIE=false;
  if (document.all && appVer >= 4) isIE=true; else
    if (document.getElementById && appVer > 4) isN6=true; else
      if (document.layers && appVer >= 4) isNC=true;
  if (isNC||isN6||isIE)
  {
    if (document.images)
    {
      var imgName = HpbImgPreload.arguments[0];
      var cnt;
      swImg[imgName] = new Array;
      for (cnt = 1; cnt < HpbImgPreload.arguments.length; cnt++)
      {
        swImg[imgName][HpbImgPreload.arguments[cnt]] = new Image();
        swImg[imgName][HpbImgPreload.arguments[cnt]].src = HpbImgPreload.arguments[cnt];
      }
    }
  }
}

function HpbImgFind(doc, imgName)
{
  for (var i=0; i < doc.layers.length; i++)
  {
    var img = doc.layers[i].document.images[imgName];
    if (!img) img = HpbImgFind(doc.layers[i], imgName);
    if (img) return img;
  }
  return null;
}

function HpbImgSwap(imgName, imgSrc)
{
  var appVer=parseInt(navigator.appVersion);
  var isNC=false,isN6=false,isIE=false;
  if (document.all && appVer >= 4) isIE=true; else
    if (document.getElementById && appVer > 4) isN6=true; else
      if (document.layers && appVer >= 4) isNC=true;
  if (isNC||isN6||isIE)
  {
    if (document.images)
    {
      var img = document.images[imgName];
      if (!img) img = HpbImgFind(document, imgName);
      if (img) img.src = imgSrc;
    }
  }
}
var swImg; swImg=new Array;


HpbImgPreload('_HPB_ROLLOVER1', 'images/inq2.jpg', 'images/inq2_r.jpg');

function exhib2004open()
{
	window.open('http://yutenji.mydns.jp/exhibition/exhibition_2/wmv/exhib2004.html','popup','width=320,height=284,scrollbars=no,resizable=no,toolbar=no,directories=no,location=no,menubar=no,status=no,left=0,top=0');
	return false;
}
function yuyucadopen()
{
	window.open('http://yuyuc.yutenji.biz/ad/yuyucad.html','popup','width=280,height=270,scrollbars=no,resizable=no,toolbar=no,directories=no,location=no,menubar=no,status=no,left=0,top=0');
}
function yuyucad080915open()
{
	window.open('http://yuyuc.yutenji.biz/ad/yuyucad2.html','popup','width=280,height=270,scrollbars=no,resizable=no,toolbar=no,directories=no,location=no,menubar=no,status=no,left=0,top=0');
}
function hamaopen()
{
	window.open('http://www.yutenji.mydns.jp/exhibition/photo/photoclass10/hama.html','popup','width=320,height=284,scrollbars=no,resizable=no,toolbar=no,directories=no,location=no,menubar=no,status=no,left=0,top=0'); 
}
function arisopen()
{
	window.open('http://www.yutenji.mydns.jp/exhibition/photo/photoclass9/aris.html','popup','width=320,height=284,scrollbars=no,resizable=no,toolbar=no,directories=no,location=no,menubar=no,status=no,left=0,top=0'); 
}
function ebisuopen()
{
	window.open('http://www.yutenji.mydns.jp/exhibition/photo/photoclass8/ebisu.html','popup','width=320,height=284,scrollbars=no,resizable=no,toolbar=no,directories=no,location=no,menubar=no,status=no,left=0,top=0');
}
function gyoenopen()
{
	window.open('http://www.yutenji.mydns.jp/exhibition/photo/photoclass7/gyoen.html','popup','width=320,height=284,scrollbars=no,resizable=no,toolbar=no,directories=no,location=no,menubar=no,status=no,left=0,top=0');
}
function l6open()
{
	window.open('http://yutenji.mydns.jp/exhibition/photo/photoclass6/l.html','popup','width=320,height=284,scrollbars=no,resizable=no,toolbar=no,directories=no,location=no,menubar=no,status=no,left=0,top=0');
}
function l5open()
{
	window.open('http://yutenji.mydns.jp/exhibition/photo/photoclass5/l.html','popup','width=320,height=284,scrollbars=no,resizable=no,toolbar=no,directories=no,location=no,menubar=no,status=no,left=0,top=0');
}
function acclogwri()
{
	document.write("<img src='http://www.hoge.com/acc/acclog.cgi?");
	document.write("referrer="+document.referrer+"&");
	document.write("width="+screen.width+"&");
	document.write("height="+screen.height+"&");
	document.write("color="+screen.colorDepth+"'>");
}
function PreLoad(obj,val) {
    var d = document;
    var img = obj;
    d.img = new Image();
    d.img.src = val;
}
function totopmsg()
	{
	location.href = "http://yutenji.biz/topmsg.html";
}
function totopmsg2()
	{
	location.href = "http://yutenji.biz/topmsg2.html";
}
function totopmsg3()
	{
	location.href = "http://yutenji.biz/topmsg3.html";
}
