Internationalization functions
This file contains variuos functions that are needed to do internationalization of NaSMail.
Internally the output character set is used. Other characters are encoded using Unicode entities according to HTML 4.0.
Everything uses global.php...
Automatic translation loading from setup.php files.
setup.php file can contain $languages array entries.
Combined decoding and encoding functions
If conversion is done to charset different that utf-8, unsupported symbols will be replaced with question marks.
Converts string from given charset to charset, that can be displayed by user translation.
Function by default returns html encoded strings, if translation uses different encoding. If Japanese translation is used - function returns string converted to euc-jp If $charset is not supported - function returns unconverted string.
sanitizing of html tags is also done by this function.
Converts html string to given charset
Makes charset name suitable for decoding cycles
Functions removes minus and characters that might be used in paths from charset name in order to be able to use it in function names and include calls.
Gettext bindtextdomain wrapper.
Wrapper solves differences between php versions in order to provide ngettext support and fix gettext codeset conversion issues. Function sets codeset to utf-8, if bind_textdomain_codeset() function is available.
Locates charset alias used by NaSMail
In 1.5 function was extended to recognize ISO646 aliases supported by extra decoding library 1.3.
Converts html character entities to numeric entities
NasMail encoding functions work only with numeric entities. This function fixes issues with decoding functions that might convert some symbols to character entities. Issue is specific to PHP recode extension decoding. Function is used internally in charset_convert() function.
Converts language code to translated language name Not all iso 639 codes are supported. Function could also be used to translate English language name to user's language.
Gettext textdomain wrapper.
Makes sure that gettext_domain global is modified.
Lookup a message in the current or selected domain (tagged form)
Function allows to separate strings that have dual meaning in English. When string is translated with nsm_t* functions, these functions strip all text before first tag.
For example: "Search" can be noun or verb in US English. Other languages might use different translations for nouns and verbs.
Plural form of nsm_tgettext
php setlocale function wrapper
From php 4.3.0 it is possible to use arrays in order to set locale. php gettext extension works only when locale is set. This wrapper function allows to use more than one locale name.
Documentation generated on Sun, 22 Nov 2009 17:36:38 +0200 by phpDocumentor 1.4.3