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
64
votes
7 answers

`po` gives `error: :1:1: error: use of unresolved identifier`

I have this problem with po in the console where trying to output a function works in itself, but outputting a variable or constant doesn't. As you can see here, although you'd think the var/let holds the content of bar.boy(), Swift somehow can't…
StuFF mc
  • 4,137
  • 2
  • 33
  • 32
33
votes
4 answers

Automatically translate .po files?

There used to be a few services that used Google Translate API V1 to automatically translate .po files. Google has stopped their V1 API and with V2 they charge $20 for 1.000.000 words. I have searched but cannot find any tool that offers…
Lisa
  • 628
  • 2
  • 6
  • 14
23
votes
6 answers

Is there a Java library for parsing gettext PO files?

Does anyone know of a Java library that will let me parse .PO files? I simply want to create a Map of IDs and Values so I can load them into a database.
Mike Sickler
  • 33,662
  • 21
  • 64
  • 90
20
votes
2 answers

.po files and gettext VS JSON and custom i18n library?

I need to develop or find some sort of lightweight gettext-like library in JavaScript for browser-side translations. Preferably the same library could be used by node.js if I'd like to translate server-side instead. 1) But, what are really the pros…
dani
  • 4,880
  • 8
  • 55
  • 95
16
votes
1 answer

Variables in PHP gettext

Possible Duplicate: How does gettext handle dynamic content? I'm using PHP's gettext. I want to translate a sentence which has a variable in it. Is this possible? For example, in English: Are you sure you want to block Alice? (Where "Alice" is…
Terence Eden
  • 14,034
  • 3
  • 48
  • 89
14
votes
3 answers

Removing all fuzzy entries of a PO file

Does anyone know a method to mass delete all fuzzy translations from a PO file. Something like: if #, fuzzy == TRUE Then SET msgstr="" AND REMOVE #, fuzzy
Martijn Burger
  • 7,315
  • 8
  • 54
  • 94
14
votes
1 answer

Get words count in PO file

How to calculate a number of words in PO file? Poedit shows only lines count. Any help will be appreciated.
Eugene Manuilov
  • 4,271
  • 8
  • 32
  • 48
13
votes
3 answers

How to I mark an empty translation (msgstr) as translated in po gettext files?

I found that is the translation for a string (msgid) is empty all gettext tools will consider the string as untranslated. Is there a workaround for this? I do want to have an empty string as the translation for this item.
sorin
  • 161,544
  • 178
  • 535
  • 806
13
votes
2 answers

How to translate a WordPress template name?

I know how to create translations for themes and templates generally by generating .po and .mo files with Poedit for example. But since template names are written in PHP comments at top of each template file there is no way to translate this as I…
lejahmie
  • 17,938
  • 16
  • 54
  • 77
12
votes
1 answer

Gettext automatic comments generation

I'm doing i18n for a php project using gettext. I'd like to use the automatic comment feature to give hints to translators when translating long phrases replaced by id. What I want to obtain is the following po file #:…
Fabio
  • 18,856
  • 9
  • 82
  • 114
12
votes
1 answer

Is there a good (PHP) frontend for editing PO files

We're working with a lot of non-professional translators: i.e. people in our overseas branches. I want to use PO files, but it's problematic getting 30+ unskilled people to edit them. I'd like a web front to edit these - ideally PHP as that's what…
Apemantus
  • 683
  • 6
  • 20
11
votes
2 answers

How can I check .mo file validity?

I'm using PHP to make .mo files out of the database and have run into a strange problem: some keys work, some don't. I think there is some kind of a problem with the generated files. How can I check, whether a .mo file is correct?
Fluffy
  • 27,504
  • 41
  • 151
  • 234
11
votes
2 answers

How to convert GNU Gettext .po files to Qt's .ts files?

Is there a tool to convert the translations in GNU Gettext .po format into Qt's native .ts format?
v_2e
  • 2,603
  • 2
  • 22
  • 29
10
votes
4 answers

How to use xliff or po l10n file formats in .net (C#/ASP.Net) development

I've been researching about xliff and po i18n files formats and it seems they are widely used and supported. There are plenty of free tools to manage the translations in xliff/po files. However, so far I could not find a good solution of how to use…
Paul
  • 1,879
  • 1
  • 23
  • 44
9
votes
2 answers

Using POEdit -- only search for strings in specific domain

I have created a WordPress theme that I wish to translate. Inside my theme I use some translations from woocommerce (i.e. ). Theese woocommerce strings, I do not wish to translate again, naturally, as they are…
FooBar
  • 5,752
  • 10
  • 44
  • 93
1
2 3
17 18