From 6b5f25507e784263bced63c4b63ea8fccfa74a0c Mon Sep 17 00:00:00 2001 From: Peter Westwood Date: Tue, 1 Sep 2009 20:44:17 +0000 Subject: [PATCH] Always filter the url in the media upload form. Fixes #10707 props nbachiyski. git-svn-id: https://develop.svn.wordpress.org/trunk@11896 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-admin/includes/media.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/wp-admin/includes/media.php b/wp-admin/includes/media.php index 014ec0351d..2beb0de199 100644 --- a/wp-admin/includes/media.php +++ b/wp-admin/includes/media.php @@ -1567,13 +1567,14 @@ var addExtImage = { * @param unknown_type $errors */ function media_upload_gallery_form($errors) { - global $redir_tab; + global $redir_tab, $type; $redir_tab = 'gallery'; media_upload_header(); $post_id = intval($_REQUEST['post_id']); - $form_action_url = admin_url("media-upload.php?type={$GLOBALS['type']}&tab=gallery&post_id=$post_id"); + $form_action_url = admin_url("media-upload.php?type=$type&tab=gallery&post_id=$post_id"); + $form_action_url = apply_filters('media_upload_form_url', $form_action_url, $type); ?>