Document the default arguments for the_widget() in the hash notation style.

Props coffee2code.
See #28298.

Built from https://develop.svn.wordpress.org/trunk@30770


git-svn-id: http://core.svn.wordpress.org/trunk@30760 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Drew Jaynes 2014-12-07 11:04:23 +00:00
parent 2a9c5910c6
commit 8b83a73511
2 changed files with 17 additions and 7 deletions

View File

@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
$wp_version = '4.1-beta2-30769';
$wp_version = '4.1-beta2-30770';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.

View File

@ -1445,12 +1445,22 @@ function wp_convert_widget_settings($base_name, $option_name, $settings) {
*
* @since 2.8.0
*
* @param string $widget the widget's PHP class name (see default-widgets.php)
* @param array $instance the widget's instance settings
* @param array $args the widget's sidebar args
* @return void
**/
function the_widget($widget, $instance = array(), $args = array()) {
* @param string $widget The widget's PHP class name (see default-widgets.php).
* @param array $instance Optional. The widget's instance settings. Default empty array.
* @param array $args {
* Optional. Array of arguments to configure the display of the widget.
*
* @type string $before_widget HTML content that will be prepended to the widget's HTML output.
* Default `<div class="widget %s">`, where `%s` is the widget's class name.
* @type string $after_widget HTML content that will be appended to the widget's HTML output.
* Default `</div>`.
* @type string $before_title HTML content that will be prepended to the widget's title when displayed.
* Default `<h2 class="widgettitle">`.
* @type string $after_title HTML content that will be appended to the widget's title when displayed.
* Default `</h2>`.
* }
*/
function the_widget( $widget, $instance = array(), $args = array() ) {
global $wp_widget_factory;
$widget_obj = $wp_widget_factory->widgets[$widget];