Macromedia flash media server 2-developing media applications User Manual

Page of 114
Portability across servers
83
Remotely persistent shared objects
You create remote shared objects that are persistent only on the server by passing a value of 
true
 for the 
persistence
 parameter in the client-side 
SharedObject.getRemote()
 
command or in the server-side 
SharedObject.get()
 command. These shared objects are 
named with the extension .fso, and are stored on the server in a subdirectory of the 
application that created the shared object. The Flash Media Server creates these directories 
automatically; you don’t have to create a directory for each instance name. 
Remotely and locally persistent shared objects
You create remote shared objects that are persistent on the client and the server by passing a 
local path for the 
persistence
 parameter in your client-side 
SharedObject.getRemote()
 
command. The locally persistent shared object is named with the extension .sor and is stored 
on the client in the specified path. The remotely persistent .fso file is stored on the server in a 
subdirectory of the application that created the shared object.
By specifying a partial path for the location of a locally persistent remote shared object, you 
can let several applications from the same domain access the same shared objects. For more 
information, se
SharedObject.getRemote()
 in the Client-Side ActionScript Language 
Reference for Flash Media Server 2.
Portability across servers
It is important to consider your development configuration and your production 
configuration when you are developing applications. 
Name application elements using all lowercase text.
  Macromedia recommends that you 
use all lowercase letters and no spaces when you name directories and files used with Flash 
Media Server and its applications. This practice helps to ensure that, during development, 
your applications work if you move files to different computers on different platforms.
 
Use a relative path or an absolute path to connect to the server. 
In your SWF file’s 
NetConnection.connect()
 statement, you can use either a relative path or an absolute path 
to connect to the registered application directory in the Flash Media Server directory. A single 
slash (/) followed by the application name indicates a relative path and lets you move the files 
to a different server without changing the code. Double slashes (//) indicate an absolute path.