Inherited Variables
Inherited Constants
Inherited Methods
Class Details
This class is usually used passing the whole HTClient cache as argument. Every provided function will extend the amount of stored information with translations composed parsing available data.
Warning: you should provide an XML file with every available, language related information. To get a suitable one, consider visiting: http://wiki.hattrick.org/CHPP_Development/Localization/ However, HTClient usually includes the xml file referenced by that web page. By default, this module will search for a file with name 'languages.xml', but you can specify a different location setting the cache key 'ht_languages'.
[ Top ]
Class Variables
$cache = false
[line 36]
Internal cache array
Tags:
- access - protected
Type: mixed
Overrides:
[ Top ]
Class Methods
__construct
HTTranslate __construct(
[array
$params = false])
[line 43]
Constructor
Tags:
- access - public
Parameters:
- array $params - Client information, used also as internal cache.
[ Top ]
htCache
array htCache(
[array
$params = false])
[line 59]
Set or retrieve internal cache, required by interface 'HT_Module'.
Tags:
- return - Current value, or the updated one
- access - public
Parameters:
- array $params - New value
[ Top ]
htTranslateMatch
array htTranslateMatch(
[array
$params = false])
[line 74]
Translate requested match using provided parameters.
Tags:
- return - Requested information, or false on error
- access - public
Parameters:
- array $params - Request paramaters as key/value pairs. If not set, will use the 'Current' slot inside the cache to search for needed parameters; required keys: MatchID, LanguageID
[ Top ]
htTranslatePlayers
array htTranslatePlayers(
[array
$params = false])
[line 160]
Translate requested team players using provided parameters.
Tags:
- return - Requested information, or false on error
- access - public
Parameters:
- array $params - Request paramaters as key/value pairs. If not set, will use the 'Current' slot inside the cache to search for needed parameters; required keys: TeamID, LanguageID
[ Top ]
htTranslateWords
array htTranslateWords(
[array
$params = false])
[line 229]
Returns available translations for specified category.
Tags:
- return - Requested information, or false on error
- access - public
Parameters:
- array $params - Request paramaters as key/value pairs. If not set, will use the 'Current' slot inside the cache to search for needed parameters; required keys: ht_translatecategory, LanguageID
[ Top ]