TOP /リクエスト テーブルの背景色を変化(#00ff00⇔#0000ff)

背景色が変化します

<table id="color_change"border="1"><tr><td>
背景色が変化します
</td></tr></table>
<script language="JavaScript"><!--
rgbcount=1;           //変化量(整数)
msec=50               //変化スピード(整数)
//-------------------------
b10=0;
g10=255;
change_flag=0;
function table_color(){
b16=b10.toString(16);
if(b16.length==1)b16="0"+b16;
g16=g10.toString(16);
if(g16.length==1)g16="0"+g16;
RGBCL="#00"+g16+b16;
document.getElementById("color_change").bgColor=RGBCL;
if(!change_flag){
b10=b10+rgbcount;
g10=g10-rgbcount;
if(g10<1)change_flag=1;
}else{
b10=b10-rgbcount;
g10=g10+rgbcount;
if(b10<1)change_flag=0;
}
}
setInterval("table_color()", msec) ;/*himajin.moo.jp*/
// --></script>