wpsmith / widget
WordPress widget base class.
Installs: 23
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
pkg:composer/wpsmith/widget
Requires
- php: >=5.6.0
- wpsmith/singleton: ^1.0.0
This package is auto-updated.
Last update: 2025-09-25 13:13:40 UTC
README
The Widget
class extends the WordPress Widget class (WP_Widget
) to add some helper methods.
Widget
expects only one method to be implemented: protected function get_defaults()
.
Widget
adds two static methods:
widget_save_inline_js()
: Outputs an inline admin script that autosaves a widget in the WordPress admin area.is_widgets_page()
: Determines whether the current WordPress admin page is the widgets page.