//specify speed of scroll (greater=faster)
speed=3;
var moveupvar;
var movedownvar;
var	crossobj;
var contentheight;

$(document).ready(function(){

crossobj=$('#scontent');
contentheight=$('#scontent').height();

if (contentheight > 200)
{
	$('#upArrow').mouseover(
	  function() {
			moveup();
	  });
	$('#upArrow').mouseout(
	  function() {
			clearTimeout(moveupvar);
	  });
	
	$('#downArrow').mouseover(
	  function() {
			movedown();
	  });
	$('#downArrow').mouseout(
	  function() {
			clearTimeout(movedownvar);
	  });
}
}
, function() {
     movedown();
     moveup();
}
);


function movedown(){
	crossobj = document.getElementById("scontent");
	if (parseInt(crossobj.style.top)>=(contentheight*(-1)+180))
	{
		crossobj.style.top=parseInt(crossobj.style.top)-speed+"px"; 
	}
	movedownvar = setTimeout("movedown()",20);
}

function moveup(){
	crossobj = document.getElementById("scontent");
	if (parseInt(crossobj.style.top)<=0)
	{
		crossobj.style.top=parseInt(crossobj.style.top)+speed+"px";
	}
	moveupvar = setTimeout("moveup()",20);
}

function cleardown(){
	clearTimeout(movedownvar);
}

function clearup(){
	clearTimeout(moveupvar);
}


