JavaScript控制背景音乐开关
<SCRIPT language=javascript type=text/javascript> function _ctrl0() { bgs.src = bgs.src==''?' music/zals.mp3':''; } </SCRIPT>
<body> <BGSOUND id=bgs src="music/zals.mp3" volume=10 loop=infinite> <input type="button" value="开关" onclick="_ctrl0()" />
</body>
来源:http://hi.baidu.com/8_8_8_8_8_8/blog/item/7a976aca2d7cce8dc817682d.html
|