Scripts
[ class tree: Scripts ] [ index: Scripts ] [ all elements ]

Procedural File: client2pot.php

Source Location: /scripts/client2pot.php



Page Details:

client2pot.php - rips gettext strings from templates, client .ini and .php

This command line script rips gettext strings from smarty files as well as .ini and .php files, and saves one file per project. If file already exists, calls msgmerge.

Usage: php client2pot.php [projectname]

Original code was tsmarty2c.php written by Sagi Bashari <sagi@boom.org.il>




Tags:

author:  Yves Bolognini <yves.bolognini@camptocamp.com>


Includes:

require_once(CARTOWEB_HOME.'scripts/pot_tools.php') [line 25]





CARTOCLIENT_PODIR [line 23]

CARTOCLIENT_PODIR = 'po/'

[ Top ]




do_dir [line 98]

void do_dir( string $dir, string $project, array &$texts, array &$plurals)

Goes through a directory



Parameters

string   $dir  
string   $project   project name or null for crawling upstream
array   &$texts   map text_to_translate => references
array   &$plurals   map of texts plurals
[ Top ]



do_file [line 63]

void do_file( string $file, array &$texts, array &$plurals)

Rips gettext strings from $file and prints them in POT format



Parameters

string   $file  
array   &$texts   map text_to_translate => references
array   &$plurals   map of texts plurals
[ Top ]



fs [line 51]

string fs( string $str)

"Fix" string - strip slashes, escape and convert new lines to \n



Parameters

string   $str  
[ Top ]



Documentation generated on Thu, 04 Sep 2008 11:39:10 +0200 by phpDocumentor 1.3.0RC3