Try adding
$attributes[] = 'loop="loop"';
at line 388 of mediaelement-js-wp.php. I.e., just after
if ($loop) {
$options[] = 'loop: ' . $loop;
This does the trick for an mp3 audio when Chrome is the browser, but does not help with Firefox (both in Ubuntu Linux). I haven’t had the opportunity yet to check other browser/operating system combinations.
OK. I think I now have the full set of corrections needed to make audio looping work as it should. The diff file is:
--- Downloads/media-element-html5-video-and-audio-player/mediaelement-js-wp.php 2012-06-01 08:37:01.000000000 -0500
+++ mediaelement-js-wp.php 2012-08-04 14:57:55.000000000 -0500
@@ -382,9 +382,10 @@
$attributes[] = 'autoplay="'.$autoplay.'"';
}
- // MEJS JavaScript options
- if ($loop) {
- $options[] = 'loop: ' . $loop;
+ // Loop options
+ if ($loop && 'false' != $loop) {
+ $options[] = '"loop": true';
+ $attributes[] = 'loop="loop"';
}
// CONTROLS array
With these changes the audio loops in Firefox 14 in both Linux and Windows 7, Chrome 21 in both Linux and Windows 7, Internet Explorer 8 in Windows 7, and Safari 5 in Windows 7 and (I am told by a co-worker) in Mac (I was not told what version). I could check it in a few other browsers, but feel that is likely to be a sufficient sample.
Thank you drmikegreen!!! your fix worked!!!
drmikegreen,
Thank you!!! The loop issue has dogged me for over a year. Thank you for your resolution of this very aggravating problem.
Hello,
WAV file Format is not working on IE. ANy suggestion?
Thanks in Advance!
Aryan
the loop doesn’t work also with mp3 files. please any help…