I'm trying to make some changes to the pop-up media uploader. Basically, I'm trying to totally remove the "gallery".

I have applied the 'media_upload_tabs' filter where I remove the gallery tab from the $tabs array, which worked.

now I want to prevent the click on the "save all changes" button from the "from computer" page to redirect to the gallery page (which is the normal action), instead I want it to lead to the library page but I could not find any way to do it.

I've had a look at the wp-admin/includes/media.php file and found inside the wp_media_upload_handler () on line 563 - 567 the call to media_upload_gallery() once the file is properly saved. I'm deducing it's the part of the code that's responsible for the redirection I want to change, but I couldn't find a hook to do so.

So my question is: how do I change this redirection? which hook, or js ?

link|improve this question
feedback

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer

 
or
required, but never shown

Browse other questions tagged or ask your own question.