View Full Version : change embedded quicktime src

04-16-2006, 05:19 PM
hi there!

i have a website on which i have a list of little quicktime movies available for download. now i want to show them directly on the site through an embedded quicktime movie.
until here it doesn't seem too difficult. the plugin shows up and loads the movie.

but now i want to change the src of this quicktime movie by clicking on one of the links in that movie list. here is the trouble. it does not work the way i have been doing it.
i am kind of confused with <option> and <embed> tags and which and how to change. a javascript alert() before and after the code line that is supposed to change the src showed me that something seems to be changed. but the new movie is not loaded into the quicktime plugin there.

here is the code. first the javascript function, then the embedding code. and at the bottom two links. the second one is supposed to change the src.

<SCRIPT type="text/javascript">

function changeMovie(){
document.getElementById("fapemovie").getElementsByTagName("param")[0].value = "files/QT_M_T_M_manitu.mov";

document.embeds[0].src = "files/QT_M_T_M_manitu.mov";

<DIV id="filme-body">

<DIV id="quicktime-movie">
<object classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B" id="fapemovie" width="400" height="300" codebase="http://www.apple.com/qtactivex/qtplugin.cab">
<param name="src" value="filme/QT_M_T_M_egoist.mov"/>
<param name="autoplay" value="false"/>
<param name="controller" value="true"/>

<embed src="filme/QT_M_T_M_egoist.mov" width="400" height="300" name="fapemovieX" autoplay="false" controller="true" enablejavascript="true" pluginspage="http://www.apple.com/quicktime/download/" />


<DIV id="filme-links">
<DIV class="film-link"><a href="files/QT_M_T_M_egoist.mov">ego ist</a> </DIV>
<DIV class="film-link"><a href="#" onclick="return changeMovie()">der fiese klaus manitu</a> </DIV>



i'd be glad to get some help. so what i want to have is a click on that link so that the quicktime movie changes to the selected one.
thx in advance