Questions tagged [po]

PO files are the format of the GNU gettext translation files.

PO files are the format of the GNU gettext translation files.

A PO (Portable Objects) file is made up of many entries, each entry holding the relation between an original untranslated string and its corresponding translation. All entries in a given PO file usually pertain to a single project, and all translations are expressed in a single target language.

They usually have to be compiled in MO (Machine Object) file to be used in applications.

263 questions
1
vote
1 answer

Angular-gettext extract annotations from javascript files

With Angular-gettext we extract annotated strings from html as specified in Gruntfile.js: grunt.initConfig({ nggettext_extract: { pot: { files: { 'po/template.pot': ['src/views/*.html'] } }, }, }) Is it possible to…
Rusty Rob
  • 16,489
  • 8
  • 100
  • 116
1
vote
1 answer

Django - gettext - Strange msgstr ""

I am having problems in translating a string. Here is my view code: advice= _("Password must contain at least 1 number or special character") sentence= advice + " ("+ special_characters + ")" response_array.append(sentence) But when I build the po…
Erwan
  • 1,055
  • 1
  • 12
  • 26
1
vote
3 answers

Why does Yii ignore my .po file?

Since Yii can not create PO files without a special extension, I just created a .po file with Poedit. I want use CGettextMessageSource and configured everything in main.php. But Yii is just ignoring my settings in main.php and my .po file…
Jurik
  • 3,244
  • 1
  • 31
  • 52
1
vote
0 answers

po vs xml for localization for CGI and PHP

I want to develop a feature for localization in my website. website is developed in CGI(C, C++) and PHP mysql. If I use po/mo for translation gettext extension is available in both CGI and PHP. I am concern about processing and overhead on server…
Praveen D
  • 2,337
  • 2
  • 31
  • 43
1
vote
2 answers

PHP multilingual site with mo

I want to make a site available in three languages, in my knowledge I can use three way to achieve this. With .po and .mo file like wordpress. With php array dumping in html file. With storing a labels in database. The database may be increase with…
Zia
  • 191
  • 12
1
vote
0 answers

use poedit to translate codeiginiter lang array

I have a codeigniter application which uses arrays to fetch the correct string for a given language. This is what the core codeigniter system does, so I assumed this was the correct way of doing things. However, this does not allow for easy…
Loopo
  • 2,204
  • 2
  • 28
  • 45
1
vote
1 answer

Translation of empty string shows po header

When I try to translates empty strings in a django template I end up with the po header showing up instead an empty string http://codex.wordpress.org/Translating_WordPress#The_PO_File_Header . I have to translate empty strings because they are in db…
maazza
  • 7,016
  • 15
  • 63
  • 96
1
vote
0 answers

PHP's gettext with en_US locale

I have a mo file /data/lang/en_US/LC_MESSAGES/test.mo (translate foo => bar) and use the following code to echo it $locale = 'en_US'; $locale_dir = '/data/lang'; putenv("LC_ALL=$locale"); setlocale(LC_ALL, $locale); bindtextdomain('test',…
Ryan
  • 10,041
  • 27
  • 91
  • 156
1
vote
1 answer

Wordpress theme translations not being implemented into admin area

I developed a wordpress theme which has a few cusotm post types in it. and i created the .po language file and it successfully imported the strings from php files. The problem is that the translations related to custom post types aren't showing in…
Nojan A.
  • 881
  • 1
  • 11
  • 27
1
vote
1 answer

boost translate: po file not work

I was used boost::locale to make a multilanguage exe, but it doesn't work. The exe always output "Hello World". How can it output "您好"? I used the example code from http://www.boost.org/doc/libs/1_53_0/libs/locale/doc/html/messages_formatting.html …
Alberl
  • 43
  • 1
  • 6
1
vote
2 answers

PO, MO translation files

I want make a multi-language app I heard about .po files but I can't locate it I made this code I made a directory in my application called languages and I put the ar_EG.po file in it and I tried languages\ar\LC_MESSAGES but it dosen't work too…
Mostafa Maklad
  • 349
  • 2
  • 13
1
vote
2 answers

tool to create from plain html file a .po file used for translation

i am using the http://i18next.com/ to translate a static website hosted on github gh-pages. are there any tools that i can use to first extract from say the index.html file and create a index.po file where the translator can localize /…
khinester
  • 3,398
  • 9
  • 45
  • 88
1
vote
4 answers

Has someone a script to extract specific strings from XML files to allow to translate them via CSV or PO files

That's my first question here, normally I provide answers ;-) Well, I'm looking for a script to extract some specific strings set into system.xml, layout xml files or similar they are used by Magento to translate them. Example: labels, menu item or…
Sylvain Rayé
  • 2,456
  • 16
  • 23
1
vote
1 answer

po message file build

Is it possible to build a *.po file to *.mo using the terminal? Currently, I have to edit the *.po file in my text editor, save it, load it via Poedit and save it again. I am working on ubuntu.
mreq
  • 6,414
  • 4
  • 37
  • 57
1
vote
1 answer

Preventing caching of gettext

How can I disable gettext caching in development phase, so I can modify mo file without restarting apache? (in http://php.net/manual/es/book.gettext.php a portion of a class is proposed for this task, but in do not work, in particular it use an…
Handsome Nerd
  • 17,114
  • 22
  • 95
  • 173