Make WordPress Core

Changeset 19019


Ignore:
Timestamp:
10/19/2011 11:01:55 PM (13 years ago)
Author:
nacin
Message:

Make $screen argument for add_meta_box() (previously $page) optional. see #18958.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/template.php

    r19015 r19019  
    840840 * @param string $title Title of the meta box.
    841841 * @param string $callback Function that fills the box with the desired content. The function should echo its output.
    842  * @param string|object $screen The screen on which to show the box (post, page, link).
    843  * @param string $context The context within the page where the boxes should show ('normal', 'advanced').
    844  * @param string $priority The priority within the context where the boxes should show ('high', 'low').
    845  */
    846 function add_meta_box($id, $title, $callback, $screen, $context = 'advanced', $priority = 'default', $callback_args=null) {
     842 * @param string|object Optional. $screen The screen on which to show the box (post, page, link). Defaults to current screen.
     843 * @param string $context Optional. The context within the page where the boxes should show ('normal', 'advanced').
     844 * @param string $priority Optional. The priority within the context where the boxes should show ('high', 'low').
     845 */
     846function add_meta_box( $id, $title, $callback, $screen = null, $context = 'advanced', $priority = 'default', $callback_args = null ) {
    847847    global $wp_meta_boxes;
    848848
Note: See TracChangeset for help on using the changeset viewer.