[wp-hackers] WP 2.2 Widgets Issue / Fix
martin.fitzpatrick at gmail.com
Thu May 31 10:36:36 GMT 2007
On 31/05/07, Knut-Olav Hoven <hovenko at linpro.no> wrote:
> > Yeh, my bad. The problem is that from WP 2.2 that function always
> > exists so it is not a reliable way to check whether Widgets are
> > enabled. Is there a new method for checking?
> I believe widgets are allways enabled in WP 2.2 (since it is no longer a
> plugin, but in the core), so there's no need to check for it.
They're always enabled but not always active - e.g. if the theme is
Previously people tended not to enable the Widgets plugin if they're
theme didn't support them (I think there was a warning also) meaning
that the check for the function also indicated that they were
Previously my plugins used to do the check & if Widgets were found and
installed it put the configuration options in the Widget (i.e. self
contained). If Widgets weren't found it output a configuration page
under Options ->
It's actually been a bit of a support/usability nightmare so I'm
stripping this out of all the plugins in favour of using the
Options->Menu method regardless. Mostly I'm just asking out of
interest: Is there a reliable way to check that Widgets are enabled
(a.k.a. supported by the current theme).
> If you need backwards compatibility, then you should keep checking for the
> function "register_sidebar_widget".
Going off on a tangent a little, but what is the impact on Sidebar
Modules (found in K2). Previously that used the same calls
(register_sidebar_widget) meaning it would die if both Modules &
Widgets were installed. Presumably now it's impossible to install
Modules because the widgets functions are built in?
Thanks for all the info by the way - I've fixed the plugins that were
causing the problems, now I'm just curious.
More information about the wp-hackers