The Problem:
I am currently in the finishing stages of a premium theme I’ve been developing and all is mostly well. For pages I have a few custom meta boxes for adding in slideshows and other additional pieces of page content and have found that the editing screen is now pretty long.
Due to the large vertical height you find yourself changing something at the bottom and then having to scroll back to the top to click “publish” or “update”. This gets tiring after editing 2 pages.
(see image below to see the problem first hand, click to enlarge)
The Question:
Is there a way to make the publish/update meta box follow the page so the “publish” and “update” buttons are always accessible and visible without having to scroll all of the way to the top?
Solution based in this StackOverflow Q&A.
Well, more a proof of concept than anything… Style and scripts being printed the lazy way.
Add a fixed
Scroll to top
div linked to an anchor near thePublish
button.You can probably do this with some CSS. Here’s a quick hack job via the webkit inspector:
This doesn’t handle the case where the UI is in single column mode though.
I found a simpler solution
Add this to your functions.php
and point it to a CSS file in your theme folder with this