用embed播放音频,谷歌浏览器chrome为什么不支持? 并且在chrome中,autostart="false"也不起作用。 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 chrome中只能用html5的audio标签。 自己找到答案了,给大家参考。chrome可以正常运行。<!doctype html><head> <meta charset="utf-8" /> <title>HTML5 Document</title> <script> function playClicked(element) { //get the state of the player if(audio_player.paused) { audio_player.play(); newdisplay = "| |"; }else{ audio_player.pause(); newdisplay = ">"; } element.value=newdisplay; }</script> </head><body><audio controls="controls" id="audio_player"> <source src="alert.wav" ></audio><input type="button" onclick="playClicked(this)" value=">"></body></html> lz给的答案是不要embed标签了吗? ext中viewport布局问题 如何获取iframe编辑器的值 大家帮忙啊 难题!100分征集解决方法 如何在页面回发的过程中,禁用页面控件的单击中功能? 关于PHP的checkbox javascript如何判断变量类型 在网页中插入的flash怎样能播放一段时间自动关闭,就像以前csdn主页上的效果??? 如何取client端的网卡串口号?? Extjs3.4 求实现一个图片下载功能 鼠标离开下拉菜单隐藏问题 html <A> href 和 onclick 如何先执行 href
<meta charset="utf-8" />
<title>HTML5 Document</title>
<script>
function playClicked(element)
{
//get the state of the player
if(audio_player.paused)
{
audio_player.play();
newdisplay = "| |";
}else{
audio_player.pause();
newdisplay = ">";
}
element.value=newdisplay;
}
</script>
</head>
<body>
<audio controls="controls" id="audio_player">
<source src="alert.wav" >
</audio>
<input type="button" onclick="playClicked(this)" value=">">
</body>
</html>