Codex tools: Log in
Contents |
Outputs all metaboxes registered to a specific page and context. Meta boxes should be registered using the add_meta_box() function.
<?php
do_meta_boxes( $page, $context, $object );
?>
Here is an example that uses add_meta_box to register a new meta box, then outputs that meta box using this do_meta_boxes function:
<?php
add_meta_box(
'my-custom-meta-box',
__( 'My Custom Meta Box' ),
'my_custom_menu_page',
'normal' );
do_meta_boxes( 'my_custom_menu_page', 'normal' );
?>
The do_meta_boxes() function is located in wp-admin/includes/template.php