w3schools scroll to top code example
Example: scroll to top
$("#scroll_icon").click(function()
{
jQuery('html,body').animate({scrollTop:0},2000);
})
$("#scroll_icon").click(function()
{
jQuery('html,body').animate({scrollTop:0},2000);
})