Ticket #241 (closed defect: fixed)
Auto-sense language and character set on a per-email basis
| Reported by: | rjl | Owned by: | dmorton |
|---|---|---|---|
| Priority: | normal | Milestone: | 1.0.3 |
| Component: | PHP scripts | Version: | 1.0.0 RC5 |
| Severity: | normal | Keywords: | language charset character set |
| Cc: |
Description
Some users may operate in multilingual environments, such that they send and receive mail in several languages. Currently, Maia only allows a user to specify a single language and character set to use to interpret all mail, so these users would need to repeatedly switch their language/charset combinations manually in order to read mail properly in the Mail Viewer.
Since the language and character set is encoded in the mail headers, however, it reasons that Maia should be able to detect these and select the appropriate supported language from among a list that the user provides, and automatically display the viewmail.php page in the appropriate language/charset when he tries to view that mail item.
Users would continue to have a "preferred" language/charset as they do now, but would need to be able to create a personal list of other languages that he understands (and which the administrator has installed language modules for). When the user wishes to look at a mail item in his Mail Viewer, the headers of the mail item could then be scanned to determine its language and charset, and if the language matches one of the ones the user has stated that he can read, the viewmail.php page can then be displayed in that language with the charset as described in the headers. No other Maia pages need be affected by this--they would continue to use the user's "preferred" language/charset.
If the mail item is in a language and charset the user has NOT indicated that he understands (or a language that the administrator has not installed a matching translation pack for), defaulting to the user's "preferred" language/charset may be a reasonable default. Alternatively, it may make sense not to display the decoded contents at all in that case, and only offer the "raw" contents. Trying to display the decoded contents of such a message should perhaps bring up a warning/error message explaining that the appropriate language/charset is not available.

