Developer |
tsunoa
rubengc |
---|---|
Update Time | June 2, 2017, 12:21 a.m. |
Donation URL: | donation |
PHP Version: | 4.0 + |
WordPress Version: | 4.8 |
Copyright: | GPLv2 or later |
Copyright URL: | Copyright Information |
wp-content/plugins/
folder locallywp-admin/plugins.php
on your site (your WP Admin plugin page)First of all you need add a filter to changes how tabs are rendered, and at this point you could add, change or move tabs.
This is the structure for a tab:
$tab = array( 'tab-identifier' => array( 'label' => 'My tab', 'selectors' => array( '#my-meta-box', '.group-of-meta-boxes', ) ) );
This is an example of tab customization:
`function custom_download_tabs( $tabs ) {
// Adding a meta box to general tab
$tabs['general']['selectors'][] = '#my-meta-box';
// Moving a tab
$temp_tab = $tabs['price-files'];
unset($tabs['price-files']);
$tabs['price-files'] = $temp_tab;
// Removing a tab
unset($tabs['feedback']);
return $tabs;
}
add_filter( 'edd_admin_tabs_download_tabs', 'custom_download_tabs');`
Note: Meta boxes that are not in a tab will be kept always visible, such as submit meta box