[wp-hackers] Third Party Widgets

Computer Guru computerguru at neosmart.net
Sat Apr 28 05:36:42 GMT 2007

Hash: SHA1

Aaron Brazell wrote:
> I have a question.
> What on earth do widget developers have to do to make their widgets
> available for the new widget system? IOW, it's no secret I run trunk. No
> big deal. I ask for breakage and that's fine. As soon as widgets were
> brought into the core, all custom widgets became unavailable. They are
> active as plugins. But unavailable on the widget page itself. It might
> be okay if thats the only place they were unavailable because, hey, who
> really wants to move widgets around anyway, right? But they aren't
> displaying in the sidebar of the blog either. In fact, the only widgets
> available to me are the stock widgets which is relatively okay.
> Again, I don't ask for a lot except I admit to asking for a broken blog.
> No problem. But what do those of us who WRITE widgets, say, for large
> blog networks with widgetized themes (:grin:) do to prepare for the WP
> 2.2 release?

I've been wondering the same thing, more or less.
Like you said: not really complaining, just wondering. A couple of days
ago, I had an error with register_widget() being redefined - so I
disabled my old widgets plugin, modified stupid widgets like "King's
Widget" & Co. that need to be in the same DIR as widgets.php, and went
to the presentation page. Till now, you can't get 3rd party widgets to

I'm looking at the code:

	register_sidebar_widget(__('Recent Comments'),
'wp_widget_recent_comments', null, 'recent-comments');
	register_widget_control(__('Recent Comments'),
'wp_widget_recent_comments_control', 320, 90, 'recent-comments');

3rd Party:
	register_sidebar_widget('Paypal Donate', 'widget_wpaypal');
	register_widget_control('Paypal Donate', 'widget_wpaypal_control', 300,

Changing that second bit of code to:
	register_sidebar_widget('Paypal Donate', 'widget_wpaypal', null,
	register_widget_control('Paypal Donate', 'widget_wpaypal_control', 300,
350, 'paypal-donations');

Fixes the problem.

Bascially, you have to suffix both function calls with a friendly
machine name or something?

I don't like it - there will be mass revolt when users find widgts no
longer work -> they're supposed to be the most easy to use stuff in WP!

- --
Computer Guru
NeoSmart Technologies

Version: GnuPG v1.4.6 (GNU/Linux)


More information about the wp-hackers mailing list