Skip to main content
Participating Frequently
July 13, 2007
Question

FLVPlayback component doesn't stream files

  • July 13, 2007
  • 2 replies
  • 320 views
Guys,

I'm trying to stream or even download flv files from Flash Media Server. The FMS is located at localhost.
I'm using a FLVPlayback component to do it. I set 'my_FLVPlybk 'as instance name.
The script is just like this:

import mx.video.*;

var listenerObject:Object = new Object();
listenerObject.playing = function(eventObject:Object) {
trace("The isLive property is " + my_FLVPlybk.isLive);
};
my_FLVPlybk.addEventListener("playing", listenerObject);

my_FLVPlybk.contentPath=" http://www.myserver.com/default.flv";
//end


>> For the contentPath i just used the following strings:
my_FLVPlybk.contentPath="rtmp://localhost/myAppName/fileName"
or
my_FLVPlybk.contentPath="rtmp="//localhost/myAppName/fileName.flv"

I also tried to use the IP address instead of localhost and it just does not work as well.

In FMS application folder , inside myAppName/streams/_definst_ folder there's a file called main.asc and its content is:

load("components");

What else can I do?
Is there something else thet i should write in the main.asc file or even in the swf file that contains FLVPlayBack component ?

If so, please help me to solve this issue.


Thanks a lot.
    This topic has been closed for replies.

    2 replies

    Participant
    July 31, 2007
    Hi As I do to do a preloader or loanding, inside the interface of the FLVPlayback?
    Participant
    July 19, 2007
    A couple thoughts...

    First, I don't know whether FMS will find main.asc if it's in the streams/_definst_ folder. Normally that's where you would put the .flv file. The main.asc file ordinarily is put in your myAppName directory.

    Second, the main.asc that you are using is designed for handling the flashcom or FMS components such as the simpleConnect and connectionLight, but it is not the main.asc that is needed for FLVPlayback. That main.asc should be located in your Flash 8 application folder under Flash 8/Samples and Tutorials/Samples/Components/FLVPlayback/main.asc

    There is a callback in that main.asc that FLVPlayback is expecting to find, and it probably will not work if that callback is missing.

    Hope that helps...