Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace varnames of empty language content #2044

Closed
rottmann opened this issue Feb 14, 2014 · 2 comments
Closed

Replace varnames of empty language content #2044

rottmann opened this issue Feb 14, 2014 · 2 comments

Comments

@rottmann
Copy link

Phalcon 1.2.6

$t = new Phalcon\Translate\Adapter\NativeArray(array('content' => array()));
echo $t->_("Hello %varname%", array('varname' => 'world'));

It shows Hello %varname%, but it should better output Hello world.

At the moment we have to create and manage a not needed language-file with the same text as it will be used in the app.

@ghost
Copy link

ghost commented Feb 23, 2014

Why not use strtr() instead of Phalcon\Translate\Adapter\NativeArray if you don't need translations at all?

@ghost
Copy link

ghost commented Feb 25, 2014

This has been implemented.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants