Tags
, ,
Asked 30+ days ago
20 Jun 2017
Views 957

posted

how to convert .po file .mo file by PHP ?

convert .po language file to .mo file By PHP , so it add extra lang constant on the fly without use any extra software like Poedit . so is there any way to comply .po file to .mo file
Mitul Dabhi

Mitul Dabhi
answered Jan 22 '18 20:17

use Poedit

using PHP , dont know how to convert *.po files to *.mo files
Edit Answer
Share
Phpworker

Phpworker
answered Jan 22 '18 20:17

Download
https://poedit.net/ install it

2. Download file from language folder
public_html/wp-content/languages
Or just file download ar.po file
And
Put the msg id and mgs text

Like suppose
“No posts found.” Text is there in the website and you want to translate to then put the “ar.po” at end of the file

msgid "No posts found."
msgstr "لا توجد مقالات."

3. Now open the ar.po file at poedit




4. Complie to .mo file



And you get. ar.mo file and upload at server
Edit Answer
Share
Post Answer