Scripts

# Procedural File: pot_tools.php Source Location: /scripts/pot_tools.php ## Page Details: pot_tools.php - useful functions for POT scripts #### Tags:
author: | Yves Bolognini <yves.bolognini@camptocamp.com>
#### Includes: require_once(CARTOWEB_HOME.'common/Encoding.php') [line 19] Encoding class for charset require_once(CARTOWEB_HOME.'common/ProjectHandler.php') [line 24] Project handler class for constants ### CARTOCOMMON_PODIR [line 14]
`CARTOCOMMON_PODIR = 'po/'`
[ Top ] ### addPhpStrings [line 137]
`void addPhpStrings( string $type, string $path, mixed $poTemplate, mixed $project)`
Finds recursively all strings in PHP code and add them to PO template Will detect methods gt() from classes I18n and I18nNoop. #### Parameters
string | $type |
string | $path |
[ Top ] ### getCharset [line 38]
`string getCharset( string $type, mixed $project)`
Finds charset in client.ini #### Parameters
string | $type |
[ Top ] ### getMapIds [line 100]
`array getMapIds( string $project)`
Gets list of map Ids by reading project directory #### Parameters
string | $project |
[ Top ] ### getProjects [line 72]
`array getProjects( [mixed $projectname = false])`
Gets list of projects by reading projects directory [ Top ] ### getTranslatedPo [line 196]
`array getTranslatedPo( string $type, mixed $project)`
Finds list of already translated PO files for a project #### Parameters
string | $type |
[ Top ] ### parseIni [line 227]
`boolean parseIni( string $project, array &$texts, [string $mapId = null])`
Parses an INI file looking for variable ending with '.label' and '.labels' #### Parameters
string | $project |
array | &$texts | map text_to_translate => references
string | $mapId | (optional)
[ Top ] Documentation generated on Fri, 21 Sep 2007 13:30:56 +0200 by phpDocumentor 1.3.0RC3