I have a string inside the t() function inside my page.tpl.php template:

print t('test string');

The string is displayed perfectly when I visit a page.
Now I'ld like to translate this string now using the "translate interface" page, but the string is not showing up there?

What am I doing wrong?
I'm using drupal 7.12 and following "multilingual" modules are enabled:

  • Content translation
  • Locale
  • ALL modules from multilingual-internationalization except contact translation and multilingual forum.

Thanks for your help.


akanelson’s picture

I've the same problem
I run Cron and Refreshed String under admin/config/regional/translate/i18n_string
Did you resolved this?


Fiable.biz’s picture

I also have the same problem.

Bluemasters theme has non translated HTML English strings, used as captions of its front page slideshow. I use Drupal 7.17. I just replaced any such static_string by


in file page--front.tpl.php and went to admin/config/regional/translate/translate but couldn't find my strings.
Moreover the available translatable strings groups there are user interface, fields, node types, menu, taxonomy and blocks; there is nothing like "template".

Is it possible to use t() in a template file? If yes, how? Have you solved this problem?

http://Fiable.biz Web site creation.

Fiable.biz’s picture

This thread has been posted in the wrong forum. The answer is in the translations forum there.

http://Fiable.biz Web site creation.