Code To Scroll page with javascript

by Preetha 2012-09-14 09:50:57

<html>
<head>
<SCRIPT LANGUAGE="JavaScript"
SRC="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js">
</SCRIPT>
<SCRIPT LANGUAGE="JavaScript">
function scroll_up()
{
$(window).scrollTop(0);
}
function scroll_to_last_div()
{
$(window).scrollTop($('#last_div').offset().top);
}
</SCRIPT>
</head>
<body>
<center>
<div style="height:100px;width:400px;">
<br><br>
</div>
<div style="height:600px;width:400px;background:#234a34;">
</div>
<div style="height:100px;width:400px;" id="last_div">
<br><br>
</div>
<div style="height:600px;width:400px;background:#fa342a;">
</div>
</center>
</body>
</html>
420
like
0
dislike
0
mail
flag

You must LOGIN to add comments