How to translate a string that contains a WordPress sitename
You can use sprintf: echo sprintf( __(‘Follow %s on Facebook’, ‘yanse’), get_bloginfo(‘name’) );
You can use sprintf: echo sprintf( __(‘Follow %s on Facebook’, ‘yanse’), get_bloginfo(‘name’) );
No. That library requires a newer version of WordPress. If you want to use that library then you need to update your version of WordPress to a more recent version.
1st as you figured out, WordPress does not offer any built in multilingual support for posts and pages. 2nd Themes, plugins etc. need a separate translation workflow than pages. But that is usually ok, since the theme does not change as much as the pages (normally). To translate the themes I would recommend Loco Translate … Read more
Create js file button.js and add js directory and list-btn.png needed (function() { tinymce.create(“tinymce.plugins.listbuttons_button_plugin”, { //url argument holds the absolute url of our plugin directory init : function(ed, url) { //add new button ed.addButton(“listbuttons”, { title : “Add Related post shortcode”, cmd : “listbuttons_command”, image : “images/list-btn.png” }); ed.addCommand(“listbuttons_command”, function() { var return_text = “[related]”; … Read more
Install the plugin WP Native Dashboard. Then you can set one language for the front-end in your wp-config.php and each user can choose another one for the back-end. See Change language of comments template for details and a screenshot.
You could try to run poedit on the plugin to see if there are untranslated strings, but it seems related to the use of child-theme template file. Maybe a quick fix could be to copy the lang files into your child theme folder too and see if it works (you will probably need to change … Read more
To get ‘Archives’ translated in your text domain you have to load a theme translation .mo file. The file in /wp-content/languages/sv_SE.po will not be used for that. Create a directory languages in your theme. Add the translations for the theme to that directory. I recommend the Codestyling Localization plugin for that. Load the theme translations … Read more
WordPress translation loading english file
_x() let’s you add a context to your strings. This is useful when you are using the same string in different places. This string may need different translations depending on the language. Your example would be : echo ‘a1 in context 1 ‘ . _x(‘a1’, ‘context1’, ‘mydomain’); echo ‘a1 in context 2 ‘ . _x(‘a1’, … Read more
translation does not work for ‘Home’