我正在尝试为视障人士创建一个音频验证系统。我有一个系统可以将几个波形文件粘合在一起,但是我无法将它们嵌入到 ie 和 firefox 中。
<script type="text/javascript">
function EvalSound(soundobj)
{
var thissound=document.getElementById(soundobj);
thissound.Play();
}
</script>
<embed src="createaudiocaptcha.php?x=46765" autostart="false" width="0" height="0" id="sound1" enablejavascript="true">
<a href="javascript:EvalSound('sound1')"><img src="gfx/speaker.gif" border="0" alt="Audio capture for visually impaired"></a>
使用这个工程,但是 ie (vista) 只会立即播放声音,它应该等到扬声器被点击。win xp 上的 IE 似乎由于某种原因被锁定。
我已经尝试为此更改嵌入:
<object type="application/x-mplayer2" height="0" width="0" id="sound1">
<param name="src" value="createaudiocaptcha.php?x=19329">
<param name="autostart" value="0">
<param name="playcount" value="1">
</object>
但是,即在winxp 上仍然会锁定- 即在vista 上会立即播放声音,而firefox 不会播放它说没有play() 功能。
有人知道为什么 ie 在 windows xp 上会锁定吗?- 建议赞赏