Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <html lang="fa-IR" dir="rtl">
- <head>
- <meta charset="UTF-8">
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
- <title>To Top</title>
- <!--[if lt IE 9]>
- <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
- <![endif]-->
- </head>
- <body style="height:5000px">
- <a style="position:fixed;bottom:20px" href="#top">برو بالا</a>
- <script src="https://code.jquery.com/jquery-2.1.1.min.js"></script>
- <script>
- $('a[href=#top]').click(function(){$('body').animate({scrollTop: 0},4000);});
- </script>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement