2007-04-24 03:05:17 +02:00
|
|
|
<?php
|
2008-09-19 03:41:18 +02:00
|
|
|
/**
|
|
|
|
* API for creating dynamic sidebar without hardcoding functionality into
|
|
|
|
* themes. Includes both internal WordPress routines and theme use routines.
|
|
|
|
*
|
|
|
|
* This functionality was found in a plugin before WordPress 2.2 release which
|
|
|
|
* included it in the core from that point on.
|
|
|
|
*
|
2015-04-12 23:29:32 +02:00
|
|
|
* @link https://codex.wordpress.org/Plugins/WordPress_Widgets WordPress Widgets
|
|
|
|
* @link https://codex.wordpress.org/Plugins/WordPress_Widgets_Api Widgets API
|
2008-09-19 03:41:18 +02:00
|
|
|
*
|
|
|
|
* @package WordPress
|
|
|
|
* @subpackage Widgets
|
|
|
|
*/
|
2007-04-24 03:05:17 +02:00
|
|
|
|
2009-03-19 23:10:18 +01:00
|
|
|
/* Global Variables */
|
|
|
|
|
|
|
|
/** @ignore */
|
|
|
|
global $wp_registered_sidebars, $wp_registered_widgets, $wp_registered_widget_controls, $wp_registered_widget_updates;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Stores the sidebars, since many themes can have more than one.
|
|
|
|
*
|
|
|
|
* @global array $wp_registered_sidebars
|
|
|
|
* @since 2.2.0
|
|
|
|
*/
|
|
|
|
$wp_registered_sidebars = array();
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Stores the registered widgets.
|
|
|
|
*
|
|
|
|
* @global array $wp_registered_widgets
|
|
|
|
* @since 2.2.0
|
|
|
|
*/
|
|
|
|
$wp_registered_widgets = array();
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Stores the registered widget control (options).
|
|
|
|
*
|
|
|
|
* @global array $wp_registered_widget_controls
|
|
|
|
* @since 2.2.0
|
|
|
|
*/
|
|
|
|
$wp_registered_widget_controls = array();
|
2015-05-28 18:20:25 +02:00
|
|
|
/**
|
|
|
|
* @global array $wp_registered_widget_updates
|
|
|
|
*/
|
2009-03-19 23:10:18 +01:00
|
|
|
$wp_registered_widget_updates = array();
|
|
|
|
|
2009-04-24 08:27:06 +02:00
|
|
|
/**
|
|
|
|
* Private
|
2015-05-28 18:20:25 +02:00
|
|
|
*
|
|
|
|
* @global array $_wp_sidebars_widgets
|
2009-04-24 08:27:06 +02:00
|
|
|
*/
|
|
|
|
$_wp_sidebars_widgets = array();
|
|
|
|
|
2009-05-29 18:32:20 +02:00
|
|
|
/**
|
|
|
|
* Private
|
2015-05-28 18:20:25 +02:00
|
|
|
*
|
|
|
|
* @global array $_wp_deprecated_widgets_callbacks
|
2009-05-29 18:32:20 +02:00
|
|
|
*/
|
2014-04-06 20:50:14 +02:00
|
|
|
$GLOBALS['_wp_deprecated_widgets_callbacks'] = array(
|
|
|
|
'wp_widget_pages',
|
2009-05-29 18:32:20 +02:00
|
|
|
'wp_widget_pages_control',
|
|
|
|
'wp_widget_calendar',
|
|
|
|
'wp_widget_calendar_control',
|
|
|
|
'wp_widget_archives',
|
|
|
|
'wp_widget_archives_control',
|
|
|
|
'wp_widget_links',
|
|
|
|
'wp_widget_meta',
|
|
|
|
'wp_widget_meta_control',
|
|
|
|
'wp_widget_search',
|
|
|
|
'wp_widget_recent_entries',
|
|
|
|
'wp_widget_recent_entries_control',
|
|
|
|
'wp_widget_tag_cloud',
|
|
|
|
'wp_widget_tag_cloud_control',
|
|
|
|
'wp_widget_categories',
|
|
|
|
'wp_widget_categories_control',
|
|
|
|
'wp_widget_text',
|
|
|
|
'wp_widget_text_control',
|
|
|
|
'wp_widget_rss',
|
|
|
|
'wp_widget_rss_control',
|
|
|
|
'wp_widget_recent_comments',
|
|
|
|
'wp_widget_recent_comments_control'
|
2014-04-06 20:50:14 +02:00
|
|
|
);
|
2009-05-29 18:32:20 +02:00
|
|
|
|
2015-08-26 04:40:23 +02:00
|
|
|
require_once( ABSPATH . WPINC . '/class-wp-widget.php' );
|
|
|
|
require_once( ABSPATH . WPINC . '/class-wp-widget-factory.php' );
|
|
|
|
require_once( ABSPATH . WPINC . '/widget-functions.php' );
|