I need to make a metabox of a WordPress Plugin called "post expirator" collapsed by default.
Right now it is open.
actually when i open a page :
My need :
That is the part of the code adding metaboxe :
* Adds hooks to get the meta box added to pages and custom post types
*/
function expirationdate_meta_custom() {
$custom_post_types = get_post_types();
array_push($custom_post_types,'page');
foreach ($custom_post_types as $t) {
$defaults = get_option('expirationdateDefaults'.ucfirst($t));
if (!isset($defaults['activeMetaBox']) || $defaults['activeMetaBox'] == 'active') {
add_meta_box('expirationdatediv', __('Post Expirator','post-expirator'), 'expirationdate_meta_box', $t, 'side', 'core');
}
}
}
add_action ('add_meta_boxes','expirationdate_meta_custom');
Thanks in advance for the reply.