I was able to use HTML5 to add a small audio clip to my client’s website. Woo hoo!
Here is the code I added…
<audio controls>
<source src="/audio/wolf.ogg" type="audio/ogg" />
<source src="/audio/wolf.mp3" type="audio/mpeg" />
Your browser does not support the audio element.
</audio>
The problem is that while the audio control looked fine in the middle of a blank page, when I add my audio clip to the left column - which is only 200px wide - the control is too big and looks like this…
You can change the width but the appearance of the tag is browser-dependent, but you can hide it, build your own interface and control the playback using Javascript.
Here is something that provides an interface to style.
You did? I see no CSS there. When I take that code and put it into my local testing, it works just fine. Not cut off at all. You are saying that code by itself creates the issue for you? That’s strange.