WordPress.org

Make WordPress Core

Ticket #17515: 17515.diff

File 17515.diff, 1.3 KB (added by wonderboymusic, 5 months ago)
  • wp-admin/includes/template.php

     
    811811 * @param string|object $screen Optional. The screen on which to show the box (post, page, link). Defaults to current screen. 
    812812 * @param string $context Optional. The context within the page where the boxes should show ('normal', 'advanced'). 
    813813 * @param string $priority Optional. The priority within the context where the boxes should show ('high', 'low'). 
     814 * @param array $callback_args Optional. Data that should be passed to the callback via the "args" property. 
     815 *              In do_meta_boxes(), there is: call_user_func( $box['callback'], $object, $box ); ($box is an array, e.g $box['args']) 
    814816 */ 
    815817function add_meta_box( $id, $title, $callback, $screen = null, $context = 'advanced', $priority = 'default', $callback_args = null ) { 
    816818        global $wp_meta_boxes; 
     
    924926                                                echo '<div class="handlediv" title="' . esc_attr__('Click to toggle') . '"><br /></div>'; 
    925927                                        echo "<h3 class='hndle'><span>{$box['title']}</span></h3>\n"; 
    926928                                        echo '<div class="inside">' . "\n"; 
    927                                         call_user_func($box['callback'], $object, $box); 
     929                                        call_user_func( $box['callback'], $object, $box ); 
    928930                                        echo "</div>\n"; 
    929931                                        echo "</div>\n"; 
    930932                                }