在浏览器中播放WAV文件的最佳方式? [英] Best way to play wav files in the browser?
本文介绍了在浏览器中播放WAV文件的最佳方式?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我别无选择,只能直接在浏览器中播放WAV文件(服务器端编码的MP3是不是一种选择,很遗憾。)
I have no choice but to play wav files directly in the browser (serverside encoding to mp3 isn't an option, unfortunately.)
什么是做到这一点的最好方法是什么?我真的很想拿HTML 5音频标签的优势,但我的目标受众包括使用IE6很多,许多青少年。至于我知道闪存不是一种选择,而是快速回放确实是至关重要的。
What's the best way to do this? I'd really like to take advantage of the HTML 5 audio tag but my target audience includes many, many teens using IE6. As far as I'm aware flash isn't an option, but speedy playback really is critical.
感谢。
推荐答案
目前,最好的办法可能只是使用HTML5 <音频>
标记。在过去,你可能会做这样的:
Nowadays, the best way is probably just to use the HTML5 <audio>
tag. In the past, you might have done it like this:
背景:
<embed src="bgsound.wav" hidden="true" autostart="true" loop="1">
在点击:
<a href="success.wav">Play Sound</a>
这篇关于在浏览器中播放WAV文件的最佳方式?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文