scrollStep=1

timerTop=""
timerDown=""

function toTop(id){
  document.getElementById(id).scrollTop=0
}

function scrollDivTop(id)
{	
	if(document.getElementById("change_arrow2").src != 'images/downarrow.gif')
	{
		document.getElementById("change_arrow2").src = 'images/downarrow.gif';
	}
	
	document.getElementById(id).scrollTop+=scrollStep
	timerDown=setTimeout("scrollDivTop('"+id+"')",10)
	
	document.getElementById("time_sh_up").value = document.getElementById(id).scrollTop;
	if(document.getElementById("time_sh_up").value == document.getElementById("time_sh_up_up").value)
	{
		document.getElementById("change_arrow1").src = 'images/up_arow_gray.gif';
	}
	document.getElementById("time_sh_up_up").value = document.getElementById("time_sh_up").value;
  
}

function scrollDivDown(id)
{
	if(document.getElementById("change_arrow1").src != 'images/uparrow.gif')
	{
		document.getElementById("change_arrow1").src = 'images/uparrow.gif';
	}
	document.getElementById(id).scrollTop-=scrollStep
	timerTop=setTimeout("scrollDivDown('"+id+"')",10)
	document.getElementById("time_sh_down").value = document.getElementById(id).scrollTop;
	
	if(document.getElementById(id).scrollTop == 0)
	{
		document.getElementById("change_arrow2").src = 'images/down_arow_gray.gif';
		clearTimeout(timerTop);
	}
	
}

function toDown(id){
  document.getElementById(id).scrollTop=document.getElementById(id).scrollHeight;
}

function stopMe(){
  clearTimeout(timerDown) 
  clearTimeout(timerTop)
}
function show_img(img_src)
{	
	document.getElementById("change_img").src = img_src;
	return false;
}