[wp-trac] [WordPress Trac] #39686: Support MediaElementJS latest version

WordPress Trac noreply at wordpress.org
Wed Jan 25 11:35:24 UTC 2017


#39686: Support MediaElementJS latest version
-----------------------------+-----------------------------
 Reporter:  rafa8626         |      Owner:
     Type:  feature request  |     Status:  new
 Priority:  normal           |  Milestone:  Awaiting Review
Component:  Embeds           |    Version:  4.7.1
 Severity:  normal           |   Keywords:
  Focuses:  javascript       |
-----------------------------+-----------------------------
 The latest version of MediaElement (3.0.2 by the end of the week) has
 covered many new media types. But there are things that need to be updated
 on your side to make it work:

 1. Remove prior files and include new files inside '''wp-
 includes/js/mediaelement''' folder
 2. On '''wp-includes/js/mediaelement/wp-mediaelement.js''':
      a. Remove lines related to Silverlight (since it’s no longer
 supported)
      b. Change line ''if ('flash' === mejs.pluginType'') to ''if
 (mejs.rendererName.match(/flash/gi) !== null)''
      c. Add in the player settings '''classPrefix: 'mejs-''''  to support
 prior class styles, since now uses BEM naming convention.
      d. Replace '''wp-includes/js/mediaelement/wp-mediaelement.min.js'''
 with changes specified above.
 3. Modify '''wp-includes/script-loader.php''' to update the reference to
 MediaElementJS changing lines:
      a. ''$scripts->add( 'mediaelement', "/wp-includes/js/mediaelement
 /mediaelement-and-player.min.js", array('jquery'), '3.0.0', 1 );''
      b. ''$styles->add( 'mediaelement', "/wp-includes/js/mediaelement
 /mediaelementplayer-legacy.min.css", array(), '3.0.0');''
      c. Translations provided in ''mejsL10n''; refer to
 https://github.com/johndyer/mediaelement/blob/master/src/js/languages/en.js
 to see new format and whole list of translations
 4. It’s worth to expand your Embeds code to use MediaElementJS to support
 new formats such as HLS, M(PEG)-DASH, YouTube, Vimeo, SoundCloud, Facebook
 and DailyMotion.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/39686>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list