Js linck cuntrole scroller


Note : Just copy and past this all on the web page sorce and then you can get output thanks..

<!DOCTYPE HTML PUBLIC “-//W3C//DTD XHTML 1.0 Transitional//EN” “http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd”>
<html xmlns=”http://www.w3.org/1999/xhtml”><head>

<meta http-equiv=”Content-Type” content=”text/html; charset=ISO-8859-1″>
<title>Untitled Document</title>
<script type=”text/javascript”>
<!–
function toTop(id){
document.getElementById(id).scrollTop=0
}

defaultStep=1
step=defaultStep
function scrollDivDown(id){
document.getElementById(id).scrollTop+=step
timerDown=setTimeout(“scrollDivDown(‘”+id+”‘)”,10)
}

function scrollDivUp(id){
document.getElementById(id).scrollTop-=step
timerUp=setTimeout(“scrollDivUp(‘”+id+”‘)”,10)
}

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

function toPoint(id){
document.getElementById(id).scrollTop=100
}
// –>
</script>

</head><body>

<a href=”#null” onclick=”toTop(‘div1′)”>Top</a>
<a href=”#null” onmousedown=”scrollDivDown(‘div1′)” onmouseup=”clearTimeout(timerDown)”>ScrollDown</a>
<a href=”#null” onmousedown=”scrollDivUp(‘div1′)” onmouseup=”clearTimeout(timerUp)”>Scroll Up</a>
<a href=”#null” onclick=”toBottom(‘div1′)”>Bottom</a>
<a href=”#null” onclick=”toPoint(‘div1′)”>Point</a>
<br><br>
<div id=”div1″ style=”overflow: auto; width: 200px; height: 300px;”>
<b>LAYER CONTENTS</b>
<p>Some Text</p><p>SOME TEXT</p><p>Some Text</p><p>SOME TEXT
</p><p>Some Text</p><p>SOME TEXT</p><p>Some Text</p><p>SOME TEXT
</p><p>Some Text</p><p>SOME TEXT</p><p>Some Text</p><p>SOME TEXT
</p><p>Some Text</p><p>SOME TEXT</p><p>Some Text</p><p>End
</p></div> <
</body></html>

Follow

Get every new post delivered to your Inbox.