0

I've bought a theme few days back, i switched to the Slovak localization.

Some of the strings were incorrect so i decided to fix them in poedit (never done that before)

Most of the strings were present in Poedit and after translating the .po file and compiling it to MO it fixed those that were there.

However there are several other strings or msgid or whatever they are called

Why aren't all of them in POedit? is there some sort of syntax issue inside the .po file?

Or should i just translate it directly inside the component's php file?

Any help greatly welcomed!

Thanks :)

0

PO/MO files' content depends on the theme/plugin developer. So you bought a half-ready theme... One way is translate strings in php files, but with this you loose the chance to update that, because updates will overwrite your changes.

I suggest you: translate the strings with po/mo, than send the updated files to the developer too, so maybe the next theme's version will contain your languages and changes too.

To translate string, use __('[STRING]', '[TEXTDOMAIN]'), for example you see a "Sidebar" string, then change that in php something similar: <?php __('Sidebar', 'mythemetextdomain'); ?>, than add to po:

msgid "Sidebar"
msgstr "SlovakianSidebarName"

Your theme's text domain maybe in the style.css header.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.