Hello :)

HPO wrote

> Marie-Aude wrote:

>> $sitetitle= _('My beautiful site') ; 
>[...]
>> the echo _($sitetitle) does not work. 

>Are you actually trying to translate your site's title twice?

>If not, gettext problems usually arise from not/wrongly setting the
>domain and the path gettext is expecting. If you have a look at the
>php manual for the gettext function, there is a complete example.

Actually no :) though it looks like. 
At first I had 
$sitetitle= _('My beautiful site') ; in variables.php
And echo $sitetitle in the second file, which is my template. 

As it did not work, I imagined the translation of the variable did not work
as non translated value was shown, and I tried to re-translate it. 
I tried both configurations (you know when you are despaired because you
can't grab why it does not work.
It is definitively not a path or configuration problem, because all other
strings are correctly translated. 
But the other strings are in other files, so this is the only case where I
define a variable that has to be translated.
--
Marie-Aude



-- 
PHP Unicode & I18N Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to