156 | | The welcome message and other messages relating to registration and logging in are in {{{current.auth.messages}}} |
157 | | which can be set in a {{{customise_auth_user_resource()}}} function in your template's config.py file. |
158 | | To see the messages that can be changed, look for the {{{messages.*}}} lines in the {{{AuthS3.__init__}}} |
159 | | function in {{{modules/s3/s3aaa.py}}}. |
160 | | These also show examples of using format elements like {{{%(system_name)s}}} to insert the system name, |
161 | | url, user name, and link to the user's profile. Use the same format elements in your messages to have |
162 | | those inserted. |
| 156 | The welcome message and other messages relating to registration and logging in are in {{{current.auth.messages}}} which can be configured in a {{{customise_auth_user_resource()}}} function in your template's {{{config.py}}} file. |
| 157 | |
| 158 | To see the messages that can be changed, look for the {{{messages.*}}} lines in the {{{AuthS3.__init__}}} function in {{{modules/s3/s3aaa.py}}}. |
| 159 | These also show examples of using format elements like {{{%(system_name)s}}} to insert the system name, url, user name, and link to the user's profile. Use the same format elements in your messages to have those inserted. |
174 | | }}} |
175 | | |
176 | | These messages will be inserted in the translation files automatically, and do not need {{{T( )}}} around them. |
177 | | For a site with multiple languages, it is suggested to include the original message in English to serve as the |
178 | | key in the translation files, and to include the format elements (for system name, etc.) in the message, so that |
179 | | the translator can rearrange them as needed. |
| 172 | |
| 173 | settings.customise_auth_user_resource = customise_auth_user_resource |
| 174 | }}} |
| 175 | |
| 176 | These messages do not need {{{T( )}}} around them. If a translation is required they need adding to the languages/xx.py file. |
| 177 | |
| 178 | As-usual, for a site with multiple languages, it is suggested to include the original message in English to serve as the key in the translation files, and to include the format elements (for system name, etc.) in the message, so that the translator can rearrange them as needed. |