The tag has no usage guidance.

learn more… | top users | synonyms (1)

0
votes
0answers
17 views

Why is my theme not translated in the backend?

My function is: add_action('init', 'wan_load_textdomain'); function wan_load_textdomain() { load_theme_textdomain('mytheme', get_template_directory() . '/languages'); } This translates in the ...
4
votes
1answer
43 views

How to escape single and plural i18n text strings?

I've come across the esc_html_e() and esc_attr_e() functions which allow me to escape translated text strings. I'm now using these instead of _e() where appropriate. The _n() function allows for both ...
4
votes
1answer
69 views

How to escape the single quote character in i18n translation strings?

How should I properly escape the single quote character in a translation string? I'm using it as an apostrophe. For example: __( '404. This isn't the page you're looking for.', 'textdomain' ); I ...
3
votes
0answers
13 views

Use override_load_textdomain for cache translation and improve performance

I have a multisite wordpress with multiple localized sites (es_ES, de_DE, it_IT). I want improve page speed by caching wordpress translation file. My code works (inspired by Tristan Darricau)! and ...
0
votes
0answers
15 views

Swedish characters unreadable after each WP update

With each update of WordPress, my site title in Swedish becomes unreadable. I then have to go in Customizer, write the site title again, and everything becomes alright. Sure it's a small ...
0
votes
1answer
24 views

How to handle single qoute in a translatable string in Wordpress

I have two translatable strings as follows in my 404.php file esc_html_e( 'I couldn't find the page you were looking for.', 'themename' ); esc_html_e( 'Try a search or one of the links below.', '...
0
votes
1answer
23 views

How to add a translatable string to post date

I am trying to add a translatable string, like "posted on:" to my Wordpress theme post dates. I have already added a font-awesome icon next to it and I'd like to have the string after the icon. The ...
0
votes
1answer
15 views

Any way to permanently translate themes?

For the reason beyond my imagination Wordpress never had chance to get real theme updater (i.e. the one that would actually update only changed files) and instead offers a-joke-called-updater, that ...
2
votes
1answer
61 views

Getting translated string through a variable

I am translating a website into different languages, and I have the following problem: Through the backend, user can select via a dropdown, a value (text string) from a list of 50 options. This ...
3
votes
1answer
35 views

Translate content, not instance, per-post

TL;DR: I'm looking for a way to translate only the content of a specific post in another language, not everything around said post (such as the 'meta' and the 'search' field like this solution seems ...
1
vote
2answers
40 views

Localization / textdomain is slow and chaotic

My theme has a lot of templates. Most of them contain messages in the usual way: echo __('This is the message','mytextdomain') This has several disadvantages. For instance, if I want to change the ...
0
votes
0answers
30 views

Theme doesn't load localization files

I create translation into Czech but I have a problem with setting up this language with the theme Blogon: I created translation. Then I copied the cs_CZ.po and the cs_CZ.mo files into to themes/...
0
votes
1answer
25 views

How to translate a string that contains a WordPress sitename

currently I have this code: <?php _e( 'Follow ' . get_bloginfo( 'name' ) . ' on Facebook', 'yanse' ); ?> But I just get Follow to translate and it echoes "Seguir 'Site name' on Facebook"
0
votes
0answers
20 views

changing languages using locale

I am trying to build a plugin to make my website available in 2 languages. I found out about the 'locale' filter, but i had a lot of trouble trying to use it. Here is what I did. I know it might not ...
0
votes
0answers
20 views

Understanding Wordpress Default Theme - twentyfifteen.1.4 >> Languages Folder

Understanding Wordpress Default Theme - Twentyfifteen.1.4 is the standardized theme designed by the wordpress people. in the language folder there is a template. just like we have .php extension or ....
3
votes
1answer
48 views

Set language per post

I have a bi-lingual blog with English as the main language and Arabic. Currently I use the post "Custom Field" to indicate that the post is Arabic and I use that in my child theme to change the ...
2
votes
1answer
31 views

Make a custom theme translate-ready

I created a my own theme, now I wish to make it translatable. I made two files: theme.pot msgid "know_more" msgstr "Vuoi saperne di più?" it_IT.po msgid "know_more" msgstr "Vuoi saperne di più?" ...
0
votes
0answers
17 views

Is it possible to create another instance of theme localization file?

I'm using a theme that has a French language pot file fr_FR.po. That file is missing some phrases. I want to add the missing phrases via another .po file (in a child theme/plugin). I don't want to ...
0
votes
1answer
59 views

Translate a child theme with pure PHP and gettext

I'm trying to translate a child theme of a parent theme that has all msgstr empty. Therefore, I've created the file de_DE.mo using the "WordPress i18n tools" recommended in the docs together with ...
0
votes
1answer
80 views

Why can I not use a class constant as text domain?

What makes Wordpress.org make an internationalization of a plugin approved? I've created my first plugin and here's the main code: https://plugins.trac.wordpress.org/browser/mastercurrency-wp/trunk/...
0
votes
0answers
14 views

translate_user_role doesn't work

I did dozens of tests, this is the code that I am tring to make work: $user = get_userdata($user_ID); /* WE NEED TO REMOVE BBP ROLES */ $roles = array(); global $wp_roles; foreach ($...
1
vote
2answers
34 views

WOO-Commerce translation | Tried it all [closed]

Hope anyone can help me with this problem. I installed WOO-Commerce all great and I set up the language to Dutch ... But as you can see there are still a lot of small things still not adjusted to ...
0
votes
1answer
57 views

Proper way to use esc_html__ and esc_attr__ etc for escaping value for translation

From the articles on Codex, esc_attr_e is proper way to escaping value for translation. But from other articles, I read about sanitizing issue and security issue for some escaping code. For my code, I ...
-4
votes
1answer
16 views

String tranlation with or without po file

I want to update some translation in it seems all translation are save in *.po file I update that file yet no update appear in website , can you help how can I make updates Thanks
0
votes
2answers
99 views

How to solve a translation function issue with no arguments and missing a text-domain?

I have a warning via WordPress Themecheck plugin WARNING : Found a translation function that is missing a text-domain. Function esc_html__, with the arguments As you can see, there is no arguments ...
0
votes
1answer
39 views

How to syntax Json output for translation?

Example I have this outputting decoded JSON $data and want to make contents translateable in wordpress. <?php echo $data['hair']['type'] )?> So in english this would output "Brown hair", but ...
-3
votes
1answer
84 views

Error in theme check “ Found a translation function…”

I have used underscores to create a unique theme. I am getting theme errors (as identified by the WP Theme Check plugin) as follows: WARNING: Found a translation function that is missing a text-...
2
votes
0answers
31 views

Translating plugin inside the theme [closed]

I've developped a WordPress Business theme and I use it to sell websites to local businesses. Everything works like a charm. But. One thing doesn't. I've included the Redux plugin into my theme. ...
0
votes
1answer
36 views

Localize strings from db

I'm using this method to translate strings in my template. The question is, what if some strings are dynamically loaded from the db? How can i translate them? I've been googling for days and even ...
0
votes
1answer
26 views

Translating a pager string

Most of Wordpress function found in themes look like this: <?php echo get_next_posts_link( 'Older posts', $the_query->max_num_pages ); // display older posts link ?> <?php echo ...
0
votes
1answer
40 views

Issue with strtotime() and Meta Box date

Shouldn't this code display the date provided from the META BOX date picker input field according to the language chosen? Explanation: The Meta Box value that is coming in though rwmb_meta() is ...
2
votes
1answer
62 views

Do you need to escape hard coded plain text?

I started playing with the Underscores starter theme and noticed it uses esc_html_e() even on plain text: <a class="skip-link" href="#content"><?php esc_html_e( 'Skip to content', '_s' ); ?&...
0
votes
0answers
23 views

Change WordPress frontend language on link/cookie

I want to change the frontend language of my WordPress (single installation, no multisite) based on either a link the user clicks or an already present cookie. So I got the following language check ...
0
votes
0answers
31 views

Is placing translation files in subdirectory in wp-content/languages folder valid?

Some of the plugin uses textdomain like just the language (eg en_GB.po, it_IT.po, tr_TR.po etc..). If i put these files directly into wp-content/languages/plugins/ directory then some files will be ...
0
votes
1answer
59 views

Translate custom order status through a filter?

I'm using this plugin to customize order statuses in Woocommerce: Woocommerce Order Status Manager In documentation it says I translate order status name using the following filter: ...
0
votes
2answers
26 views

Conflict with single and double quotes

This might be a very silly question but I am losing my hair over this.. So basically, I have the following line of code" 'Default' => '<img src="' . THEMEROOT . '/admin/images/default....
1
vote
1answer
16 views

Translating a word with locotranslate, but wordpress does display another by default

I use wpadverts plugin and Loco translate to translate the plugin. I'm trying to translate from English to French the "Email" word to "Email" :D. When I translate the word in LocoTranslate plugin, it ...
0
votes
0answers
42 views

How to correctly translate custom posts url rewrites?

I've got a custom post type 'product'. I've just added the rewrite option: 'rewrite' => array('slug'=>__('products','jungle'),'with_front'=> false) Fine. But I want mydomain.com/products ...
0
votes
0answers
17 views

Load custom language(.mo) file after admin selection option on theme options

I have different .po and .mo file on theme's language folder, I want to give facility to the site admin to select language file which are on the language folder from theme options making drop down of ...
0
votes
1answer
36 views

Multi Site Translate Strings

I've finally made it to setup a multisite. http://www.jeroenbrugman.com/ Now. There are some things I need to change. Like the button on the contact page. It says "Stuur bericht" on both my sites. ...
0
votes
0answers
38 views

I18n l10n of plugin does not show the translation

I tried to Internationalize I18n one of free plug-ins (after 7 hours of trial I decided to ask for help). But I'm not able to get translations displayed. What I did: inserted the definition of text ...
1
vote
1answer
63 views

Load plugins'.mo and .po files from a directory

What I'm trying to do is simple: I have so much WordPress plugins, and 3/4 of them aren't translated in my language, so I want and can translate them all without problems, but I would insert ...
0
votes
1answer
22 views

Custom taxonomy name not being translated in post manager page

I'm having problems trying to display the proper translation for my taxonomy name, specifically in the post manager page. Where it should show the taxonomy's name translated to Spanish, it displays ...
0
votes
0answers
143 views

Poedit ASCII errors ( Wordpress )

I am trying to translate a wordpress theme to Arabic and I am totally new to the translation field. I followed the steps in this question and I added a new domain to my theme instead of hard coding ...
1
vote
2answers
30 views

Default string not appearing want to translate

I am trying to make my theme translatable so I am using the following command to output text. But its just returning an empty value some reason? No error is displayed <?php __('PLAYER POINTS AT A ...
0
votes
1answer
40 views

Force translated language on front

I'm facing a really simple issue : We made a theme for a multisite wordpress (see here : http://www.agence-malttt.fr/) and translated it with Loco Translate for French. It's still showing English ...
1
vote
1answer
53 views

How to translate a WordPress.org plugin?

WordPress.org launched recently a new translation mechanism via https://translate.wordpress.org/. What steps should I make to translate a plugin at wp.org plugin repository correctly? Can I remove ...
0
votes
0answers
18 views

Translation for child theme

I built a child theme for adding ar translation, but I can't get it translated to Arabic. My functions.php: /** * Setup My Child Theme’s textdomain. * * Declare textdomain for this child theme. * ...
0
votes
1answer
29 views

Plugin Translation project not found

Today I go to our plugin page in WordPress.org and see the translation part under the support forum part. However, when I click to translate this plugin, it displays "Not found". I joined the ...
0
votes
1answer
69 views

When translating not all string are present in POedit

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 ...