views:

95

answers:

0

My client has a site where they stream in MP4 videos from a Flash Media Server. This works all fine but now they want to move all the videos to their local server (accessible on a sub-domain) and this is where the sh*t hits the fan. I've tried many combinations but haven't gotten it to work so far.

One part of the problem is that I can't test in real-time on their server due to restrictions. I've tested locally with a MP4 file in a sub-folder from where the SWF is located and that works fine but as soon as it goes on a test server (where there's a crossdomain.xml that grants that test server rights to access media files on the client's server) the video will not stream. Here's an example of the scenario:

Let's say this is my test video:

test.mp4

It's in a folder on the client's server with sub-domain:

http://media.client.com/videos/

The site (i.e. SWF) is on http://www.client.com/

... Could somebody give me an example of how to definitely use AS3 NetConnection.connect() and NetStream.play() with these parameters? I've tried pretty much any variation but with no success. The AS3 docs are very vague about this and the fact that I can't test on-site doesn't help either.

_netConnection.connect("http://media.client.com/");
...
_netStream.play("videos/test.mp4");

... doesn't work.

_netConnection.connect("http://media.client.com/videos/");
...
_netStream.play("test.mp4");

... doesn't work either (throws exception if I remember correctly).