How are .mo files used?
-
I currently have a dual language wordpress site, English and my native language. I use the Polylang plugin to obtain and manage the multilanguage functionality and everything works fine.
There are however some harcoded strings that cannot be translated through the plugin’s interface. I am using the Vertex theme.
An example is the 404 page template (no-results.php). Within that file there are 2 strings, enclosed in the
esc_html_e()
function (which I think is the Vertex’s version of__()
function). Example:esc_html_e('No Results Found','Vertex');
How can I display the above text in the right language based on the user’s prefference, using the theme’s .mo files? I already know that I can use
get_bloginfo('language')
but I would preffer not to use this method.I have already translated the above string in the theme’s .po file with PoEdit, and uploaded it back along with the new .mo as well, to no avail.
Actually, I cannot understand how those .mo files are supposed to work.
Can anybody explain it to me please?
- The topic ‘How are .mo files used?’ is closed to new replies.