andynewbie
06-23-2007, 06:20 AM
Ok, I have a very specific problem related to using sound files on my website.
I have been using the following code to run several small sized versions of Windows Media Player on the page.
<tbody><tr><td><object id="mediaPlayer" classid="CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95" codebase="http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701" standby="Loading Microsoft Windows Media Player components..." type="application/x-oleobject" height="45" width="170"><param name="fileName" value="soundtest2.mp3"><param name="animationatStart" value="true"><param name="transparentatStart" value="true"><param name="autoStart" value="false"><param name="showControls" value="true"><param name="loop" value="false"><embed type="application/x-mplayer2" pluginspage="http://microsoft.com/windows/mediaplayer/en/download/" id="mediaPlayer" name="mediaPlayer" displaysize="4" autosize="-1" bgcolor="darkblue" showcontrols="true" showtracker="-1" showdisplay="0" showstatusbar="-1" videoborder3d="-1" src="sountest2.mp3" autostart="false" designtimesp="5311" loop="false" height="45" width="170"></object></td></tr><!-- ...end embedded WindowsMedia file --></tbody>
This worked great in Internet Explorer, but for some reason not in Firefox, where whenever I loaded the page it always asked for new plugins and then couldnt find them or use them.
Im sure that there would be a way around this by messing with the preferences in Firefox, but I dont want my visitors to have to do this, because they will probably just quit and leave.
Does anybody know a way to make this work in both IE and Firefox, without messing around with extra plugins?
OR :
I did find this piece of code, which actually does work in both browsers without even mentioning searching for extra plugins :
<title>embed_v3</title></head><body><object id="objMediaPlayer" classid="CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95" type="application/x-oleobject" height="45" width="170">
<param name="FileName" value="soundtest2.mp3"><embed type="application/x-mplayer2" src="soundtest2.mp3" autostart="false" name="objMediaPlayer" height="45" width="170"></object><br></body></html>
As I said, this wrks fine in both IE and Firefox - the problem is, that it autostarts when I load the page, which is not what I want. What is very wierd is that this only happens in IE, not in Firefox. I have tried sticking in an "autostart=false" but that doesnt do any good. Does anybody know why this happens? Is it to do with the CLSID? Is there any way to stop it?
Thanks heaps for your help
I have been using the following code to run several small sized versions of Windows Media Player on the page.
<tbody><tr><td><object id="mediaPlayer" classid="CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95" codebase="http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701" standby="Loading Microsoft Windows Media Player components..." type="application/x-oleobject" height="45" width="170"><param name="fileName" value="soundtest2.mp3"><param name="animationatStart" value="true"><param name="transparentatStart" value="true"><param name="autoStart" value="false"><param name="showControls" value="true"><param name="loop" value="false"><embed type="application/x-mplayer2" pluginspage="http://microsoft.com/windows/mediaplayer/en/download/" id="mediaPlayer" name="mediaPlayer" displaysize="4" autosize="-1" bgcolor="darkblue" showcontrols="true" showtracker="-1" showdisplay="0" showstatusbar="-1" videoborder3d="-1" src="sountest2.mp3" autostart="false" designtimesp="5311" loop="false" height="45" width="170"></object></td></tr><!-- ...end embedded WindowsMedia file --></tbody>
This worked great in Internet Explorer, but for some reason not in Firefox, where whenever I loaded the page it always asked for new plugins and then couldnt find them or use them.
Im sure that there would be a way around this by messing with the preferences in Firefox, but I dont want my visitors to have to do this, because they will probably just quit and leave.
Does anybody know a way to make this work in both IE and Firefox, without messing around with extra plugins?
OR :
I did find this piece of code, which actually does work in both browsers without even mentioning searching for extra plugins :
<title>embed_v3</title></head><body><object id="objMediaPlayer" classid="CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95" type="application/x-oleobject" height="45" width="170">
<param name="FileName" value="soundtest2.mp3"><embed type="application/x-mplayer2" src="soundtest2.mp3" autostart="false" name="objMediaPlayer" height="45" width="170"></object><br></body></html>
As I said, this wrks fine in both IE and Firefox - the problem is, that it autostarts when I load the page, which is not what I want. What is very wierd is that this only happens in IE, not in Firefox. I have tried sticking in an "autostart=false" but that doesnt do any good. Does anybody know why this happens? Is it to do with the CLSID? Is there any way to stop it?
Thanks heaps for your help