I was trying to add A [B]“Fixed Scroll To Top”[I]Button[URL=”http://www.jqueryscript.net/animation/Customizable-Fixed-Scroll-To-Top-Button-With-jQuery-toTop-js.html”][FONT=Book Antiqua]Here’s the website with the Jquery code and the tutorial on how to install it[/FONT]
I followed the rules from that tutorial, and this is what I came up with. Let me know if anything’s wrong.
[CODE]<script src=”http://pllfans.com/trabajo/wp-content/uploads/2016/03/jquery-1.12.2.min_.js”></script>
<script src=”http://pllfans.com/trabajo/wp-content/uploads/2016/03/toTop.js”></script>
<script>
$(‘body’).toTop({
// CSS styles for the scroll to top button
css: {
position: “fixed”,
right: ‘2rem’,
bottom: ‘1rem’,
fontSize: ‘4rem’,
cursor: ‘pointer’,
color: ‘#1e1e1e’
},
// text for the scroll to top button
symbol: ‘⌃’,
// animation speed for the scrolling effect
scrollUpSpeed: 2000,
// distance from top of the webpage to trigger the plugin
triggerHeight: 250
});
</script>
Then, on the tutorial website you can read something like this
[QUOTE]
2. And then call the function .toTop() on the body tag.
$(‘body’).toTop();
I don’t know how to do this! I’ve tried some stuff but it didn’t work. Here’s what I added [B]before[I]<body>[B]after[I]</head>
[CODE]<body onload=”.toTop()”>
I’m clearly doing something wrong, and I need your help to figure it out. [B]I know this might be a dumb question but if I understand this I can make big things. [U]THANK YOU IN ADVANCE.