[wp-trac] [WordPress Trac] #29707: Native Audio Player

WordPress Trac noreply at wordpress.org
Fri Sep 19 11:34:55 UTC 2014


#29707: Native Audio Player
-------------------------------+------------------------------
 Reporter:  noelb              |       Owner:
     Type:  defect (bug)       |      Status:  new
 Priority:  normal             |   Milestone:  Awaiting Review
Component:  Media              |     Version:  4.0
 Severity:  normal             |  Resolution:
 Keywords:  reporter-feedback  |     Focuses:
-------------------------------+------------------------------
Changes (by johnbillion):

 * keywords:   => reporter-feedback


Old description:

> The native audio player is defaulted to 'visibility: hidden'.  This bug
> was also in the previous versions of wordpress and when I upgraded to 4.0
> all audio in my posts went missing.
>
> The fix is to edit  media.php and search the style and delete the
> 'visibility:hidden'
>

> wp-includes/media.php
>
>  $html_atts = array(
>                 'class'    => apply_filters( 'wp_audio_shortcode_class',
> 'wp-audio-shortcode' ),
>                 'id'       => sprintf( 'audio-%d-%d', $post_id,
> $instances ),
>                 'loop'     => $atts['loop'],
>                 'autoplay' => $atts['autoplay'],
>                 'preload'  => $atts['preload'],
>                 'style'    => '/* width: 300px; */',  <------
> visibility:hidden was here
>         );

New description:

 The native audio player is defaulted to 'visibility: hidden'.  This bug
 was also in the previous versions of wordpress and when I upgraded to 4.0
 all audio in my posts went missing.

 The fix is to edit  media.php and search the style and delete the
 'visibility:hidden'


 wp-includes/media.php

 {{{
 $html_atts = array(
                 'class'    => apply_filters( 'wp_audio_shortcode_class',
 'wp-audio-shortcode' ),
                 'id'       => sprintf( 'audio-%d-%d', $post_id, $instances
 ),
                 'loop'     => $atts['loop'],
                 'autoplay' => $atts['autoplay'],
                 'preload'  => $atts['preload'],
                 'style'    => '/* width: 300px; */',  <------
 visibility:hidden was here
 );
 }}}

--

Comment:

 Thanks for the report.

 The audio player is made visible by the MediaElement.js JavaScript which
 is enqueued when audio or video is embedded in a post. If this is not
 happening then there may be an issue with your theme, or with a plugin on
 your site, or with your browser.

 Can you try deactivating the plugins on your site and switching to the
 default theme and seeing if the problem persists?

--
Ticket URL: <https://core.trac.wordpress.org/ticket/29707#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list