B.8. Locale Translation Keys

Keys in a locale file are usually in all capitals, using only A-Z, 0-9, and underscores for the key name. In general, we use prefix to provide a hint for its usage.

Table B.2. Conventional Translation Key Prefixes
Prefix Usage
ACTION_ Displayed text for page-controller action names
DESCR_ Form element descriptions (long text)
ERR_ Logic error and exception messages
FAILURE_ Failure messages, typically form-related
FORMAT_ Formatting strings for the locale
HEADING_ Heading titles
INVALID_ Invalid data message
LABEL_ Form element labels (short text)
LEGEND_ Fieldset legend titles
SUCCESS_ Success messages, typically form-related
PROCESS_ Displayed text for action processes, typically submit-button values
TEXT_ General-purpose text
WARNING_ Warnings, typically form-related