//スクロール
function gotoTop() {
  var IE  = navigator.appName.indexOf("Microsoft Internet Explorer",0) != -1;
  if( IE ){
    position = document.body.scrollTop;
  } else {
    position = window.pageYOffset;
  }
  movePosition();
}

function movePosition() {
  position = Math.floor(position*0.8);
  if( position > 0.1 ){
    window.scrollTo(0,position)
    setTimeout("gotoTop()",30);
  } else {
    window.scrollTo(0,0);
  }
}

//コピーライト
function Year(){
now=new Date();
if(now.getYear()>=2000){document.write(now.getYear())}
else{document.write(now.getYear()+1900)};
}

//イメージロールオーバー
//<img src="aaa.jpg" alt="" class="imgover" />

rollovers=function(off,on){
img=document.getElementsByTagName("img");p=[];
off_reg=new RegExp(off+"(\.[a-z]+$)","i");on_reg=new RegExp(on+"(\.[a-z]+$)","i");
for(var x=0,i;i=img[x];x++){ if(i.src.match(off_reg)){p[x]=new Image();p[x].src=i.src.replace(off_reg,on+"$1");
i.onmouseover=function(){this.src=this.src.replace(off_reg,on+"$1");};
i.onmouseout=function(){this.src=this.src.replace(on_reg,off+"$1");};};};};
