I would like to add new tab to upload manager and inside list images from
theme_folder/images/patterns
I tried something like this to add a tab but it does not work for me since it is adding tabs on the side of media manager but on image upload that tab is not visible.
function custom_media_upload_tab_name( $tabs ) {
$newtab = array( 'tab_slug' => 'Patterns' );
return array_merge( $tabs, $newtab );
}
add_filter( 'media_upload_tabs', 'custom_media_upload_tab_name' );
function custom_media_upload_tab_content() {
// Add you content here.
echo 'Hello content';
}
add_action( 'media_upload_tab_slug', 'custom_media_upload_tab_content' );
to be precise this is where I would like to add a new tab and in that tab I would like to list images from theme folder.
I am aware that media manager JS needs to be rewritten for it but to be honest I dont know where to start. Looks like I need to write completely new template for media manager in order to achieve this.
I went trough all suggestions but seems like no one is reading the question. As advised "I tried something like this to add a tab but it does not work for me since it is adding tabs on the side of media manager but on image upload that tab is not visible."
So for now no one is able to find the solution for this.