#44 XTRA_CODE hacks

open
nobody
None
5
2007-02-15
2007-02-15
Tomas Kuliavas
No

SquirrelMail uses special XTRA_CODE hooks to change the way interface works in some translations. These hooks have been pushed into SquirrelMail 1.3.x by risumail developers in order to improve Japanese support.

Main issues.
1. XTRA_CODE makes interface work correctly only in translation which uses them. Other translations are forced to use generic functions. For example: Japanese translation reads euc-jp, shift-jis and utf-8 encoded emails. Other translations could not read euc-jp and shift-jis until SquirrelMail got appropriate decoding functions.

2. XTRA_CODE changes the way interface works and requires workarounds in all plugins that depend on some internal part modified by those hooks. For example, every time code uses $default_charset, developers must add extra switches for Japanese. Japanese translation declares that it uses iso-2022-jp charset, yet interface runs in euc-jp. Every time CJK decoding functions are executed, they must be turned off in Japanese translation.

Risumail developers haven't contributed to SquirrelMail development after they pushed their code to core scripts. They post code updates only on own site, push code to SquirrelMail packagers, add hacks without actually explaining what is broken is SquirrelMail code and claim that their mods fix broken SquirrrelMail code because some unnamed smtp servers can't handle current code version.

I strongly recommend removing XTRA_CODE support and doing things in the way that works for all translations.

Discussion