發新話題
打印

音樂點播機 (按鈕式)

音樂點播機 (按鈕式)

<script>
<!-- Activate Cloaking Device
var browser_check="";
if(navigator.appName=="Netscape" && parseInt(navigator.appVersion)>=3)
browser_check="n3_or_better";
if(navigator.appName.substring(0,9)=="Microsoft")
browser_check="msie";
function playSong(selection)
{
if (browser_check=="n3_or_better" || browser_check=="msie")
window.location.href=selection;
else
alert("\nSorry but this sound scheme is NOT supported by your browser.");
}
// Called by View Source button - displays text file of source.
function viewSource()
{
alert("\nA text file with source will be loaded to the full window.\n\nUse your browser BACK button to return to the examples.");
top.window.location.href="java";
}
// Called by About This button
function about()
{
alert("\nOf course, this example requires sound capabilities.\n\nOnly Netscape 3 or better and MSIE are allowed access to this sound scheme.");
}
// Deactivate Cloaking -->
</script>
<div align="center"><center>
<table border="0">
<tr>
<td><input type="button" value="music (1)"
onclick="playSong('http://www.bunbunhk.com/dl/j1.mid')"></td>
<td><input type="button" value="music (2)"
onclick="playSong('http://www.bunbunhk.com/dl/j2.mid')"></td>
<td><input type="button" value="music (3)"
onclick="playSong('http://www.bunbunhk.com/dl/j3.mid')"></td>
<td><input type="button" value="music (4)"
onclick="playSong('http://www.bunbunhk.com/dl/j4.mid')"></td>
<td><input type="button" value="music (5)"
onclick="playSong('http://www.bunbunhk.com/dl/j5.mid')"></td>
</tr>
</table>
</center></div>

 

 

music (1) <<< 可更改為歌曲名稱

 

可隨意加減按鈕,原句增加及更改數字即可

<td><input type="button" value="music (5)"
onclick="playSong('http://www.bunbunhk.com/dl/j5.mid')"></td>

 

http://www.bunbunhk.com/dl/j5.mid  << 音樂網址,可更改

 

 

如不能顯示語法效果可貼去本站語法測試板試看

 

 

我唔係人.........

TOP

複製上列語法



我唔係人.........

TOP