From d26e6fa963224ecc828a5a9f76bd7a1893bc9de4 Mon Sep 17 00:00:00 2001 From: Ryan Boren Date: Wed, 4 Mar 2009 22:54:10 +0000 Subject: [PATCH] Filter text to be sent to editor when used From URL. Props nbachiyski. fixes #6588 git-svn-id: https://develop.svn.wordpress.org/trunk@10710 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-admin/includes/media.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/wp-admin/includes/media.php b/wp-admin/includes/media.php index 60213ea879..0dd9c3c938 100644 --- a/wp-admin/includes/media.php +++ b/wp-admin/includes/media.php @@ -464,6 +464,7 @@ function media_upload_image() { } if ( !empty($src) ) $html = "$alt"; + $html = apply_filters('image_send_to_editor_url', $html, $src, $alt, $align); return media_send_to_editor($html); } @@ -555,6 +556,7 @@ function media_upload_audio() { $title = basename($href); if ( !empty($title) && !empty($href) ) $html = "$title"; + $html = apply_filters('audio_send_to_editor_url', $html, $href, $title); return media_send_to_editor($html); } @@ -608,6 +610,7 @@ function media_upload_video() { $title = basename($href); if ( !empty($title) && !empty($href) ) $html = "$title"; + $html = apply_filters('video_send_to_editor_url', $html, $href, $title); return media_send_to_editor($html); } @@ -661,6 +664,7 @@ function media_upload_file() { $title = basename($href); if ( !empty($title) && !empty($href) ) $html = "$title"; + $html = apply_filters('file_send_to_editor_url', $html, $href, $title); return media_send_to_editor($html); }