ok here is my problem,
I am trying to change the source file of the mediplayer using javascript, my script works perfectly in "Internet Explorer", but no matter what I do, it doesn't work in Firefox
here is my player :
[HTML]
<OBJECT classid=CLSID:2 2D6F312-B0F6-11D0-94AB-0080C74C7E95
height=276 id=mediaPlayer type=applicatio n/x-oleobject width=320
standby="Loadin g Video...">
<embed
id="mediaPlayer "
type="applicati on/x-mplayer2"
pluginspage="ht tp://www.microsoft.c om/windows/windowsmedia/download/"
src="dummy.asx"
name="mediaPlay er"
width="320"
height="276"
autostart="0"
showcontrols="0 " >
</embed>
</OBJECT>
[/HTML]
and here is the javascript function called to change the source:
any help is really appreciated.
I am trying to change the source file of the mediplayer using javascript, my script works perfectly in "Internet Explorer", but no matter what I do, it doesn't work in Firefox
here is my player :
[HTML]
<OBJECT classid=CLSID:2 2D6F312-B0F6-11D0-94AB-0080C74C7E95
height=276 id=mediaPlayer type=applicatio n/x-oleobject width=320
standby="Loadin g Video...">
<embed
id="mediaPlayer "
type="applicati on/x-mplayer2"
pluginspage="ht tp://www.microsoft.c om/windows/windowsmedia/download/"
src="dummy.asx"
name="mediaPlay er"
width="320"
height="276"
autostart="0"
showcontrols="0 " >
</embed>
</OBJECT>
[/HTML]
and here is the javascript function called to change the source:
Code:
<script language="javascript"> filename = 'somename.wmv'; movieName = 'mediaPlayer'; if (window.document[movieName]) {window.document[movieName].fileName = filename;} if (navigator.appName.indexOf("Microsoft Internet")==-1){if (document.embeds && document.embeds[movieName]) document.embeds[movieName].fileName = filename; } else {document.getElementById(movieName).fileName = filename;} </script>
Comment