On Wed, 2 Apr 2008, Andreas Schamberger wrote:

> I've got a question regarding the new TemplateTranslationTiein:
> For ezPublish templates there is the ezlupdate program. What are the
> plans for ezcTemplate? Update of ezlupdate or plain PHP solution?

There is some code that extracts the translations from templates 
already, but it has not been converted into a full blown script yet. For 
the eZ Publish version that will use the new template and translation 
components there will most likely be a PHP-only solution as replacement 
for ezlupdate.

> What's the schedule for this missing part of the TemplateTranslationTiein?

We hope to get it done before the release, but there are some slightly 
more importent things to be done first. If you are interested in helping 
out a bit, that would be most welcome. I attached a script that shows 
how to extract strings from a template.

> Another thing I would recommend to add to the TemplateTranslationTiein
> is a developer mode for the TemplateTranslationTieIn. I'd like to see a
> development property in ezcTemplateTranslationConfiguration that makes
> the ezcTemplateTranslationProvider catch the Exceptions for missing
> translations/translation files and just return the string from the
> template. This solution makes it possible to develop with a template
> that doesn't have a valid translation file yet.

Hmm, I see your point here; however, I don't quite think that this is an 
elegant solution. I don't always want to catch the exception, and 
rethrow it when the configure option is not set, nor having two bits of 
code here for each case. Could you file a feature request for this 
please?

regards,
-- 
Derick Rethans
eZ components Product Manager
eZ systems | http://ez.no
<?php
set_include_path( "/home/derick/dev/ezcomponents/trunk:." );

require 'Base/src/ezc_bootstrap.php';

$source = new ezcTemplateSourceCode( $argv[1], $argv[1] );
$source->load();

$parser = new ezcTemplateParser( $source, new ezcTemplate() );
$tst = $parser->parseIntoNodeTree();

$et = new ezcTemplateTranslationStringExtracter( $parser );
$eted = $tst->accept( $et );

var_Dump( $et->getTranslation() );
-- 
Components mailing list
[email protected]
http://lists.ez.no/mailman/listinfo/components

Reply via email to