You site now have the "Back to Top" link whenever you scroll down your page.
Now, what if you wish to put an image instead of Back to Top?
This too can be done easily. Just change the following code
echo '<a id="totop" href="#">Back to Top</a>';to
echo '<img id="totop" alt="" src="Paste your image url here" />';
and you are done!
Hope you like this tutorial!
UPDATE: 30th November 2015, You can keep the code functioning even when updating your theme, the steps are similar but this time, you paste the codes inside the Child Theme of your Main Theme (Parent Theme). This way, you paste only one time and don't need to bother again, also, we don't need to worry about messing up coding in the Parent Theme.
Join the Discussion
Write something…