You don't need to use a socket for this.

Load the data with a URLLoader, setting URLLoader.dataFormat to
URLLoaderDataFormat.BINARY.

You'll get a ByteArray. Pass that to Loader::loadBytes() wait for the
complete event to fire and you're all set.

Well, almost. If the loaded swf is in a different domain, you need a
crossdomain. If I recall correctly, this case also involved
some LoaderContext particular setup (can't remember the details, though).

You don't need to do anything server-side if you are serving the swf as a
normal file.

Cheers
Juan Pablo Califano

2010/6/8 Tom Gooding <[email protected]>

> Hi,
>
> Does anyone know how to get an external swf (hosted on a regular webserver)
> into the Loader class - accessed via the low-level flash.net.Socket class
> into a ByteArray.
>
> It seems this is possible, but I can't find any examples of how to handle
> it either server side (we use Java here) or how the AS3 client would need to
> work.
>
> I have found this which looks like it may have been relevant, but the files
> have been taken down:  http://www.bytearray.org/?p=32
>
> If anyone has any ideas I'd appreciate it,
>
> Tom
> _______________________________________________
> Flashcoders mailing list
> [email protected]
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to