MACROMEDIA FLASH MEDIA SERVER 2-SERVER-SIDE ACTIONSCRIPT LANGUAGE Manuale Utente Pagina 80

  • Scaricare
  • Aggiungi ai miei manuali
  • Stampa
  • Pagina
    / 240
  • Indice
  • SEGNALIBRI
  • Valutato. / 5. Basato su recensioni clienti
Vedere la pagina 79
80 Deploying Flash Media Server
Once you have defined such a mapping, you can use the symbol in one of the XML
configuration files.
To use a symbol in place of a normal string in a configuration file, specify the symbol name,
with the characters
${ before the symbol name, and } after the symbol name. Whenever the
server finds something of the form
${SYMBOL}, it performs a lookup to see if the symbol is
mapped to a string. If no mapping is found, then
${SYMBOL} is not substituted, and is taken
literally. Otherwise, it is substituted.
For example, in the Vhost.xml file, you might use the previously defined symbol as follows:
<VirtualHost>
<VirtualDir>
<Streams>foo;${VIR_DIR}</Streams>
</VirtualDir>
</VirtualHost>
When the server encounters the symbol, it checks whether the symbol named VIR_DIR is
mapped to anything. It then finds that it is mapped to
c:\streams in the substitution.xml
file. The symbolic mapping in the previous XML fragment is equivalent to the following
XML without symbols:
<VirtualHost>
<VirtualDir>
<Streams>foo;c:\streams</Streams>
</VirtualDir>
</VirtualHost>
If the substitution.xml file is missing and you try to use text substitution symbols in the
configuration files, the server will interpret the symbols as literal strings.
Predefined symbols
The two predefined symbols ROOT and CONF do not need to be mapped, and are always
available. The
ROOT symbol is mapped to the location of the FMSMaster.exe file, as this
example shows:
<AppsDir>${ROOT}\..\..\myapps</AppsDir>
The CONF symbol is mapped to the location of the Server.xml file, as this example shows:
<AppsDir>${CONF}\..\yourapps</AppsDir>
Vedere la pagina 79
1 2 ... 75 76 77 78 79 80 81 82 83 84 85 ... 239 240

Commenti su questo manuale

Nessun commento