You can try switching completely to unobtrusive javascript, you limit
yourself by adding all the code in the HTML like that.  I've found
that document.getElementById("videoBox").innerHTML=''; can do some
neat stuff.

On Oct 12, 7:06 pm, eljefeoc <[EMAIL PROTECTED]> wrote:
> Thanks Aran.  I was able to get it to the link to function just fine
> in Safari on a MAC but not in Firefox.  Which makes me think about
> another problem... say the page loads in a system without Flash
> installed so Quicktime gets enabled, now all my links wont be
> compatible with the QT plugin.  So my guess is that for every link I
> will need it to send three possible functions as well.  Is that
> assumption correct?  Is it possible to create a function that sends
> different scripts based on the player plugin?
> Thanks,
> Jeff
>
> On Oct 7, 11:57 pm, "Aran Rhee" <[EMAIL PROTECTED]> wrote:
>
> > That's because the ID of you media player is "videoBox", Not "player". So
> > you really want something like:
>
> > // standard function in the <head> tag
>
> > function changeVid(mediaURL)
> > {
> >         var player = document.getElementById("videoBox");
> >         player.sendEvent("LOAD", mediaURL)
>
> > }
>
> > // you can get more funky with what you can pass in the LOAD event object
> > // check out :http://code.jeroenwijering.com/trac/wiki/FlashAPI
>
> > // link on page
> > <a href="javascript:changeVid('SW-1-600337h264-desktop.m4v')">load a
> > video</a>
>
> > Aran
>
> > -----Original Message-----
> > From: [email protected] [mailto:[EMAIL PROTECTED] On
>
> > Behalf Of eljefeoc
> > Sent: Wednesday, 8 October 2008 5:26 PM
> > To: SWFObject
> > Subject: Loading a new video into swfobject player.sendEvent('LOAD',object);
>
> > Hello,
> > I am trying to figure out how to send a new video to an established jw
> > player.  Basically I was able to get it to work using the examples
> > given on the site and following the example video page as well.
>
> > However I want build the site around the "Flash + iPhone: SWFObject 2
> > + MP4" post from bobbyvandersluis .
>
> > So my question is using a page link or later thumbnail style link, how
> > do I build a script that will change the video in the JW Player
> > without refreshing the page.
>
> > Here is my basic frame work for my page:(http://akorn.tv/primer3/
> > index3.html)
>
> > <html xmlns="http://www.w3.org/1999/xhtml"; lang="en" xml:lang="en">
> >         <head>
> >                 <title>Primer Test 3</title>
> >                 <meta http-equiv="Content-Type" content="text/html;
> > charset=iso-8859-1" />
> >                 <script type="text/javascript" src="swfobject.js"></script>
> >                 <script type="text/javascript">
> >                         swfobject.registerObject("videoBox", "9.0.0");
>
> >                 </script>
> >         </head>
> >         <body>
> >                 <div>
> >                         <object id="videoBox" classid="clsid:D27CDB6E-
> > AE6D-11cf-96B8-444553540000" width="600" height="337"><!-- Flash +
> > Internet Explorer, Safari, Opera -->
> >                                 <param name="movie" value="player.swf" />
> >                                 <param name="flashvars"
> > value="file=8008_Open2web600.mp4&amp;image=8008_Open2web600.jpg&amp;author= 
> > A
> > korn
> > Entertainment
> > LLC&amp;screencolor=FFFFFF&amp;duration=28&amp;autostart=false" />
> >                                 <param name="allowfullscreen" value="true"
> > />
> >                                 <param name="allowscriptaccess"
> > value="always" />
> >                                 <!--[if !IE]>-->
>
> >                                 <object type="application/x-shockwave-flash"
> > data="player.swf"
> > width="600" height="337"><!-- Flash + Firefox, other -->
> >                                         <param name="flashvars"
> > value="file=8008_Open2web600.mp4&amp;image=8008_Open2web600.jpg&amp;author= 
> > A
> > korn
> > Entertainment
> > LLC&amp;screencolor=FFFFFF&amp;duration=28&amp;autostart=false" />
> >                                         <param name="allowfullscreen"
> > value="true" />
> >                                         <param name="allowscriptaccess"
> > value="always" />
>
> >                                         <object type="video/mp4"
> > data="8008_Open2web600-click.jpg"
> > width="600" height="337"><!-- QuickTime, iPhone -->
> >                                                 <param name="controller"
> > value="false" />
> >                                                 <param name="src"
> > value="8008_Open2web600.jpg" />
> >                                                 <param name="href"
> > value="8008_Open2web600.mp4" />
> >                                                 <param name="target"
> > value="myself" />
> >                                 <!--<![endif]-->
> >                                                 <img
> > src="8008_Open2web600.mp4" alt="Mario Klingemann presenting
> > on Flash on the Beach 2007 (Brighton, UK)" /><!-- alternative content
> > -->
> >                                 <!--[if !IE]>-->
> >                                         </object>
> >                                 </object>
> >                                 <!--<![endif]-->
> >                         </object>
> >                 </div>
> >                 <br>
> >                 <a href="javascript:player.sendEvent('MUTE')">mute/sound
> > toggle</a>
>
> >                 <br>
> >                         <a
> > href="javascript:document.player.sendEvent('LOAD',
> > 'SW-1-600337h264-desktop.m4v')">load a video</a>
> >                 <br>
> >                         <a href="#"
> > onclick="document.player.sendEvent('STOP');
> >         player.sendEvent('LOAD',
> >         'http://akorn.tv/primer3/8008_Open2web600.mp4');
> >         ">load video 2</a>
>
> >         </body>
> > </html>
>
> > As you can see I have added three links of various flavors on the
> > bottom to try to control the video... with no luck.
>
> > Thanks for the help.
>
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"SWFObject" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/swfobject?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to