Back to top Button



Hello! :slight_smile:

Is there any way to add a “back-to-top” button or text to the blog?

I think it would be handy… :wink:


Hey, you can do that today with a bit of Javascript:

var topP = document.createElement("p"); = "center";
topP.innerHTML = '<a href="#">Back to top</a>';
var cont = document.getElementById("wrapper");
if (cont !== null) {
    // Add to blog index and tag pages
} else {
    // Add to individual blog post page
    cont = document.getElementById("post-body");
    cont.insertAdjacentHTML("afterend", topP.outerHTML);


Nice, that worked! :slight_smile:
Is there a way to add utf-8 encoding to replace the text with Greek translation?
I tried to do it and I only got question mark symbols.



I might have to make some changes on our end to get Greek text working. Could you send me an example URL or the exact JS you’re using (either privately, or on this thread)? Then I can make the changes and verify that they work.