soundFile=sound[randomNum(sound.length)]
//-- Decide whether to use embed or bgsound.
if (navigator.appName.indexOf('Microsoft')>=0) {
document.writeln ('<bgsound src="'+soundFile+' " loop="-1">')
}else{
document.writeln ('<embed src="'+soundFile+'" hidden=true autostart=true loop=true>')
}