// JavaScript Document

function mask(){
 document.getElementById("sure").style.display="block";
   var rubyid=document.createElement("div");
   document.body.appendChild(rubyid);
   rubyid.id="ruby_id";
   rubyid.style.position="absolute";
   rubyid.style.background="#333";
   rubyid.style.left=0;
   rubyid.style.top=0;   
   rubyid.style.zIndex=100;
   var bodysize=[];
   bodysize[0]=(document.documentElement.scrollWidth>document.documentElement.clientWidth)? document.documentElement.scrollWidth:document.documentElement.clientWidth;
   bodysize[1]=(document.documentElement.scrollHeight>document.documentElement.clientHeight)?document.documentElement.scrollHeight:document.documentElement.clientHeight;
   rubyid.style.width=bodysize[0]+"px";
   rubyid.style.height=bodysize[1]+"px";
   if(document.all){
   rubyid.style.filter="alpha(opacity=80)";
   }
   else{rubyid.style.opacity=0.8;}
 }
 function removediv(){
 var rubyid=document.getElementById("ruby_id");
 document.body.removeChild(rubyid);
 document.getElementById("sure").style.display="none";
 }
 
 

function scrol_div(){
var scrollTop = window.pageYOffset  
                || document.documentElement.scrollTop  
                || document.body.scrollTop  
                || 0;

 document.getElementById("sure").style.top=scrollTop+70+"px";
};



function setdu(id){
		var Divs=document.getElementById(id).getElementsByTagName("DIV");
		for(var i=0;i<Divs.length;i++){
		var idnum=parseFloat(Divs[i].getAttribute("name").toString());
		var thelen=142-idnum*14;
		//alert(thelen);
		Divs[i].getElementsByTagName("P")[0].style.width=thelen+"px";
		}
	}

function changetab(id1,id2){
	var one=document.getElementById(id1);
	var two=document.getElementById(id2);
	one.style.display="block";two.style.display="none";
		}
		
		window.onload=function(){
			var pcrimg=document.getElementById("pcr_img");
			var tbrimg=document.getElementById("tbr_img");
			pcrimg.onclick=function(){changetab("pcr","tbr");pcrimg.src="images/tab_img_on.jpg";tbrimg.src="images/tab_img_2.jpg";}
			tbrimg.onclick=function(){changetab("tbr","pcr");pcrimg.src="images/tab_img.jpg";tbrimg.src="images/tab_img_2_on.jpg";}
			
			}
			
			
			
			
			
			
