
		document.getElementById('home_cool').scrollLeft = 0;
		var t = document.getElementById('home_cool').scrollWidth;
		document.getElementById('cool_img').innerHTML += document.getElementById('cool_img').innerHTML;
		
		function re(){
			var num = document.getElementById('num').innerHTML;
			var boardimg = document.getElementById('home_cool');
			
			if(boardimg.scrollLeft < num){
				boardimg.scrollLeft += 10;
			}else if(boardimg.scrollLeft > num){
				boardimg.scrollLeft -= 10;
			}else if(boardimg.scrollLeft == num){
				stopree();
			}
			
		}	
	
		function auto_re(){
			var num = document.getElementById('num').innerHTML;
			var boardimg = document.getElementById('home_cool');	
			if(boardimg.scrollLeft == t){
				boardimg.scrollLeft = 0;
			}else if(boardimg.scrollLeft < num){
				boardimg.scrollLeft += 10;
			}else if(boardimg.scrollLeft > num){
				boardimg.scrollLeft += 10;
			}else if(boardimg.scrollLeft == num){
				stopauto_ree();
				//stopscroll(); 
			}
		}
		
		function auto(num){
			if(!num){i=1;}else{i=num;}
			as = setInterval(function(){auto_board(i,"");},5000);
		}
		function autostop(){
			clearInterval(as);
		}
		
		function ree(){
			ss = setInterval(re,1);
		}
		
		function stopree(nownum){
			var num = document.getElementById('num').innerHTML;
			var boardimg = document.getElementById('home_cool');
			if(boardimg.scrollLeft == num){
				clearInterval(ss);
				auto(nownum);
			}
		}
		
		function auto_ree(){
			sa = setInterval(auto_re,10);
		}
		function stopauto_ree(){
			clearInterval(sa);
		}
	
		function board(num,url){
			document.getElementById('board'+num).style.color = "#fff";
			for(i=0;i<5;i++){
				if(i !== num){document.getElementById('board'+i).style.color = "#666";}
			}
			//document.getElementById('boardt').innerHTML = document.getElementById('boardt'+num).innerHTML;
			var boardi = new Array(0,320,640,960,1280);
			document.getElementById('num').innerHTML = boardi[num];
			ree();
			nownum = num;
		}
		
		function auto_board(num,url){
			if(document.getElementById('home_cool').scrollLeft == 1600){ document.getElementById('home_cool').scrollLeft = 0;}
			document.getElementById('board'+num).style.color = "#fff";
			for(i=0;i<5;i++){
				if(i !== num){document.getElementById('board'+i).style.color = "#666";}
			}
			//document.getElementById('boardt').innerHTML = document.getElementById('boardt'+num).innerHTML;
			var boardi = new Array(0,320,640,960,1280);
			document.getElementById('num').innerHTML = boardi[num];
			auto_ree();
			if(num < 4){i = num+1;}else{i = 0;}
			num = null;
		}
		
		auto();