Download ERW
Transcript
Chapter 7. Installation and Configuration
$_ERW_decimalComma
The character for the decimal comma (i.e., the character that separates triples of
digits in the integer part of a number).
$_ERW_dateFormat
A number denoting the date format you prefer. It can be ERW_DATE_ISO,
ERW_DATE_EU, or ERW_DATE_US. See also Chapter 11.
Warning
Do not make on-the-fly changes to this value—changing
it should be considered as severe as installing a
new version of ERW. Browser caching of JavaScript
code can cause pernicious inconsistencies (see also
the Section called Caching in Chapter 3.
$_ERW_supportedLocales
A PHP array of locales for which translations are available. HTTP language negotiation will be used to select the most appropriate one. This variable defaults
to array("en-US").
ERW will try to match the locale requested by the browser with one of the supported ones. As a last resort, it will use a country-specific language (such as
en-US) for a generic language (such as en). Thus, the order in the array is important: if you specify array("en-UK", "en-US"), upon a generic request for en
the user will get the en-UK locale.
$_ERW_fileBasePath
An absolute path indicating the directory where all files relative to the database
are stored. A hierarchy of subdirectories (one for each entity, and then one for
each fileset) will be created automatically when files are uploaded.
Important: This directory (and its subdirectories) must be writable by the user under
which Apache runs (usually apache or nobody).
$_ERW_authenticate
The name of a PHP file, containing code for custom authentication. See
Chapter 5.
$_ERW_globalPrivileges
A conjunction of the bit masks ERW_SELECT, ERW_UPDATE, ERW_INSERT and
ERW_DELETE that gives the global privileges. The default value is ERW_SELECT |
ERW_UPDATE | ERW_INSERT | ERW_DELETE (i.e., all privileges to everybody).
See the Section called The Authorisation System in Chapter 5.
$_ERW_authDenied
Default error messages for denied authorisations. This array must associate to
the keys selectDenied, updateDenied, insertDenied and deleteDenied corresponding error messages (an empty message will silence the error display).
The messages can be further customised using the post-authorisation hook.
$_ERW_basicRealm
If you set up custom authentication, this is the basic realm that will be shown to
the user in the authentication dialog.
55