Sound bei Klick funktioniert nicht
Kristian Fürst
- javascript
Ich beziehe mich auf das Posting http://forum.de.selfhtml.org/archiv/2002/1/2563/#m14466 .
selbiges funktioniert bei mir nicht. kann mir jemand erklären warum nicht und was ich ändern muss?
im qt der seite steht:
...
<script src="sound.js" type="text/javascript"> </script>
...
<a href="1.html" onmousedown="MM_controlSound('play','embedname','klick.wav')">
...
die sounddatei heisst "klick.wav"
in der datei "sound.js" steht:
function MM_controlSound(x, _sndObj, sndFile) { //v3.0
var i, method = "", sndObj = eval(_sndObj);
if (sndObj != null) {
if (navigator.appName == 'Netscape') method = "play";
else {
if (window.MM_WMP == null) {
window.MM_WMP = false;
for(i in sndObj) if (i == "ActiveMovie") {
window.MM_WMP = true; break;
} }
if (window.MM_WMP) method = "play";
else if (sndObj.FileName) method = "run";
} }
if (method) eval(_sndObj+"."+method+"()");
else window.location = sndFile;
}
MfG,
Kristian, beinahe verzweifelnd