A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: FLV to play in same window

  1. #1

    FLV to play in same window

    I have multiple links that point to different FLVs. I would like the FLVs to play all in the same spot on the web page... How is that achieved?

    Thank you in advance,
    Astro

  2. #2
    I wanted to clarify what I originally posted just in case that didn't make sense...

    I need to have several FLVs play in one FLVplayback component. Here's what I've tried so far...

    Created an FLA with the following layers:
    - actions
    - component
    - customUIcomponents
    - vidComponent
    - interface

    I added components to the following layers:
    + List component (instance named lbPicker) into the component layer
    + FLVplayback component (instance named cptPlayer) into the vidComponent layer
    + FLVplayback Custom UI components added into the customUIcomponents layer:

    + playPauseButton (instance named cptPlayPause)
    + stopButton (instance named cptStop)
    + seekBar (instance named cptSeek)
    + bufferingBar (instance named cptBuffer)
    + volumeBar (instance named cptVolume)
    + muteButton (instance named cptMute)

    I added the following code to the actions layer:

    Code:
    import mx.video.FLVPlayback;
    var cptPlayer:FLVPlayback;
    
    cptPlayer.playPauseButton = cptPlayPause;
    cptPlayer.stopButton = cptStop;
    cptPlayer.seekBar = cptSeek;
    cptPlayer.bufferingBar= cptBuffer;
    cptPlayer.volumeBar = cptVolume;
    cptPlayer.muteButton = cptMute;
    
    function pickVideo(myVid:String): Void{
    cptPlayer.contentPath = myVid;
    }
    
    lbPicker.change = function(evt:Object) {
    pickVideo(evt.target.selectedItem.data);
    }
    I added the FLV filenames into the List (lbPicker) data parameter and the corresponding titles in the labels parameter...

    When I compile and run the SWF, the information shows up in the List (lbPicker), but when I select one of the FLVs, it doesn't play

    Any thoughts?

  3. #3
    Member
    Join Date
    Jun 2006
    Location
    Cardiff, UK
    Posts
    44
    are the videos appearing in a particular order, or on selection of a button?

    in the past i have had different buttons set for different flv, and used actionscript on buttons:

    video.setMedia ("blah.flv")

    video is my instance name for the display area.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center