Flash Lite 2.x and 3.0 ActionScript Language Reference

connect (NetConnection.connect) method

Opens a connection to a server. Through this connection, you can play back audio or video (FLV) files from the local file system, or you can invoke commands on a remote server.

When using this method, consider the Flash Player security model and the following security considerations:

  • By default, the website denies access between sandboxes. The website can enable access to a resource by using a cross-domain policy file.
  • A website can deny access to a resource by adding server-side ActionScript application logic in Flash Media Server.
  • You cannot use the NetConnection.connect() method if the calling SWF file is in the local-with-file-system sandbox.
  • You can prevent a SWF file from using this method by setting the allowNetworking parameter of the the object and embed tags in the HTML page that contains the SWF content.