There are (among others) two common ways of customizing the sidebar on an individual post:
-
Create a new sidebar for the post, using code or plugins like Custom sidebars, WP Custom Sidebar, Per Page Sidebars, or similar.
-
Create conditional display rules on individual widgets, using plugins like Widget Logic or Conditional Widgets.
Option 1 can lead to a proliferation of sidebars on your Widgets page if you have more than a few posts you want to customize. Option 2 can quickly lead to long, complicated, and difficult-to-manage sidebars in the backend. And with both 1 and 2, the user has to manage things on a separate page than the page she wants to customize.
So:
Are there any pluginsâor related attemptsâto add a sidebar/widget editor, (like in Appearance » Widgets) to the post edit screen? The idea would be to give the user the option to override the default sidebar on a given page in a convenient and intuitive way.
It might work something like this:
- Add a metabox containing a checkbox to override default sidebar on that post or page.
- If checked, display interface to select widgets. (this could be the full widget ‘bank’, but, more economically, it could just be a dropdown with names of widgets).
- For the interface and saving, recycle code from Appearance » Widgets
- For front of site, include filter to replace the default sidebar if
_override_sidebar
meta field says so.
I’m surprised I can’t seem to find a plugin for this. Do you have suggestionsâplugins, pitfalls, related code?
I’m sure there is a more elegant approach (I’d love to know about!). Anyhow: I’d like to offer a solution.
You could create a default sidebar with default widgets and a custom sidebar with all available custom widgets. Then you use a combination of the following plugins: simple fields and widget logic to only show a selection of widgets.
How to:
This way works quite well for me, though it is not very pretty.
Hope it helps or gives ideas for further extension.
Looks like someone’s working on that 🙂
There’s a beta version for download in the thread.
[Update]
It is an official plugin in the Repo now:
http://wordpress.org/extend/plugins/buckets/
Two plugins that may be what you’re looking for: