0

I'm building an HTML5 widget for iBooks Author that allows the user to play different parts of an audio clip. Although I include controls in the player code thus:

<audio id="clip" controls><source src="clip.m4a" type="audio/m4a" /></audio>

or simply

<audio id="clip" src="clip.m4a" controls/></audio>

I end up with only a play/pause button when I export to iBooks to preview on the iPad as in the following screen shot:

Screenshot of player with only a play button and no other controls

I've tried this with ogg, m4a, mp3 and wav formats and all give the same issue.

Is this an issue with my code? I've wondered if it is simply a limitation of HTML5 media in iBooks because they would prefer me to use the built in media widget. Unfortunately, iBooks Author's built in media widget does not allow options of listening to only parts of a clip, essential for the language-learning materials I'm building.

I could include two separate audio files, but doing that duplicates media and, over the course of the entire book, significantly increases book file size.

Thanks in advance...

Mikawa Ben
  • 76
  • 10

1 Answers1

-1

I believe that iBooks is using a similar rendering engine to Safari and the WebView used by other apps. In my app, I have a WebView that loads controls similarly to what you describe.

I believe that all audio elements in iOS display only a play/pause button. You may need to role your own player to gain additional functionality, such as skip forward and skip backwards buttons.