diff --git a/wp-includes/media.php b/wp-includes/media.php
index c45ef65c8..4003a41bb 100644
--- a/wp-includes/media.php
+++ b/wp-includes/media.php
@@ -1397,33 +1397,35 @@ function wp_oembed_add_provider( $format, $provider, $regex = false ) {
}
/**
+ * Generate HTML for the editor media buttons (image, video, audio).
*
+ * @since 3.1.0
*
- *
+ * @return string HTML
*/
-function get_media_buttons(){
+function get_media_buttons() {
$do_image = $do_audio = $do_video = true;
if ( is_multisite() ) {
$media_buttons = get_site_option( 'mu_media_buttons' );
- if ( empty($media_buttons['image']) )
+ if ( empty( $media_buttons['image'] ) )
$do_image = false;
- if ( empty($media_buttons['audio']) )
+ if ( empty( $media_buttons['audio'] ) )
$do_audio = false;
- if ( empty($media_buttons['video']) )
+ if ( empty( $media_buttons['video'] ) )
$do_video = false;
}
$out = '';
if ( $do_image )
- $out .= _media_button(__('Add an Image'), 'images/media-button-image.gif?ver=20100531', 'image');
+ $out .= _media_button( __( 'Add an Image' ), 'images/media-button-image.gif?ver=20100531', 'image' );
if ( $do_video )
- $out .= _media_button(__('Add Video'), 'images/media-button-video.gif?ver=20100531', 'video');
+ $out .= _media_button( __( 'Add Video' ), 'images/media-button-video.gif?ver=20100531', 'video' );
if ( $do_audio )
- $out .= _media_button(__('Add Audio'), 'images/media-button-music.gif?ver=20100531', 'audio');
+ $out .= _media_button( __( 'Add Audio' ), 'images/media-button-music.gif?ver=20100531', 'audio' );
- $out .= _media_button(__('Add Media'), 'images/media-button-other.gif?ver=20100531', 'media');
+ $out .= _media_button( __( 'Add Media' ), 'images/media-button-other.gif?ver=20100531', 'media' );
- $context = apply_filters('media_buttons_context', __('Upload/Insert %s'));
+ $context = apply_filters( 'media_buttons_context', __( 'Upload/Insert %s' ) );
return sprintf($context, $out);
@@ -1440,18 +1442,29 @@ function media_buttons() {
}
add_action( 'media_buttons', 'media_buttons' );
-function _media_button($title, $icon, $type) {
- return "";
+/**
+ * {@internal Missing Short Description}}
+ *
+ * @since unknown
+ * @access private
+ */
+function _media_button( $title, $icon, $type ) {
+ return "";
}
-function get_upload_iframe_src($type) {
+/**
+ * {@internal Missing Short Description}}
+ *
+ * @since unknown
+ */
+function get_upload_iframe_src( $type ) {
global $post_ID, $temp_ID;
- $uploading_iframe_ID = (int) (0 == $post_ID ? $temp_ID : $post_ID);
- $upload_iframe_src = add_query_arg('post_id', $uploading_iframe_ID, 'media-upload.php');
+ $uploading_iframe_ID = (int) ( 0 == $post_ID ? $temp_ID : $post_ID );
+ $upload_iframe_src = add_query_arg( 'post_id', $uploading_iframe_ID, 'media-upload.php' );
if ( 'media' != $type )
- $upload_iframe_src = add_query_arg('type', $type, $upload_iframe_src);
- $upload_iframe_src = apply_filters($type . '_upload_iframe_src', $upload_iframe_src);
+ $upload_iframe_src = add_query_arg( 'type', $type, $upload_iframe_src );
+ $upload_iframe_src = apply_filters( $type . '_upload_iframe_src', $upload_iframe_src );
- return add_query_arg('TB_iframe', true, $upload_iframe_src);
+ return add_query_arg( 'TB_iframe', true, $upload_iframe_src );
}