Questions tagged [translation]

Translation is the term used to describe the effort to make WordPress (with themes and plugins) available in languages other than English for people from different locales, who have different dialects and local preferences. The process involves two main topics: internationalization (i18n) and localization (l10n).

Filter by
Sorted by
Tagged with
0
votes
0answers
19 views

__() function inside html tags

sprintf(<span style="display:block;margin:4px 0 0;line-height:1.25em;font-size:95%%"> Image credit: %$s</span> esc_html( $credit )); I would like to add __() function to translate Image ...
3
votes
2answers
2k views

change only the theme language

My wordpress admin is in french. and my theme is in arabic. i have two files mo : arabic and french. i used this : add_filter( 'locale', 'change_locale' ); function change_locale(){ return 'pt_AR'; }...
0
votes
0answers
17 views

load_plugin_textdomain was called with an argument that is deprecated since version 2.7.0 with no alternative available

I tried to update Avada theme using ftp. I deleted Avada folder and copied that again from zip file I downloaded. Since then, I am facing these errors: Deprecated: load_plugin_textdomain was ...
0
votes
2answers
234 views

How to handle single quote 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
0answers
9 views

Loco Translate: Custom Post and Custom Taxonomy Labels not translated in wp-admin menu

I am currently translating all of my plugins with loco translate. This is working fine on frontend and in all metaboxes in the backend, but not in the wp-admin menu: The red circled word should be in ...
0
votes
1answer
12 views

translate wordpress website from english to arabic

I install weglot plugin and add arabic as destiantion language but when change website from english to arabic i get this error Not Found The requested URL /ar/ was not found on this server how can ...
0
votes
1answer
17 views

Translate string inside twig template

I am trying to translate a string inside a placeholder in a twig (timber) template. But I cannot detect the string in WPML string translation. <input type="text" id="s" name="s" value="" ...
0
votes
0answers
12 views

How to conditionally concatenate and translate two very long strings?

I am conditionally concatenating a very long string onto another very long string. Then I am returning it as the argument to another function. I think I should translate the strings individually first,...
37
votes
11answers
50k views

How to create .pot files with POedit?

I've spent hours today on what seemed like something really simple, which is to create a .pot file for a Wordpress theme that I'm creating. I've read the Smashing Magazine article, the Tutsplus ...
0
votes
0answers
12 views

Advantage of saving term translations with polylang?

Ok, so I'm trying to automate the generation of posts and custom taxonomies in different languages, and it's all working. What I did (summary): create posts with wp_insert_post() set language of ...
1
vote
1answer
5k views

Add a string to file .pot using Poedit

I want to add a string to a pot document for language, but it says there’s an error. I have opened file .pot with a text editor and I have add this code #:D:\Programe\InstantWP\InstantWP_4.3.1\...
2
votes
2answers
5k views

How to add extra language packs to WordPress

I've got a multisite which I installed in Dutch. Therefore English and Dutch are available in the general settings tab. But I need to add German and French. I can't select any other language from the ...
2
votes
1answer
251 views

How to load translation in JavaScript?

I am struggling to load translation in JavaScript for my simple plugin. Translation works for PHP, but not in JS. What seems to be the problem, how can I debug this? I have loaded text domain in my ...
0
votes
4answers
3k views

get_the_date() for translating date format

I want to display dates in Hindi format like jan 10 using get_the_date() function. What I have tried so far: echo get_the_date(_e('F j')); which outputs: F jJanuary 10, 2017.
0
votes
1answer
28 views

WordPress filter load_textdomain_mofile not working inside a child theme's functions.php but works form inside a plugin

Function in a plugin is behaving differently than function in the functions.php inside a child theme. I have a custom simple plain plugin with nothing but the following code in it and it works ...
0
votes
1answer
14 views

Language does not switch while cache is enabled

At my website I have a button when pressed PHP script through ajax write session variable to change language and reload page. But when I enable caching every time is loading default language. When ...
0
votes
0answers
8 views

Wordpress: How to change the text of automatic E-Mails e.g. after changing your password? (German localization) #2

According to this, which was posted some years ago, I understand it is (was) possible to change the password changed mail text using Poedit. I need a clarification though: The .po file containing the ...
0
votes
1answer
824 views

How to translate wordpress error message

I have a problem and I am not finding the variable to solve, I have a site in WP and when I try to login and neither the password nor the email exists, I get the error message: ERROR: The username or ...
0
votes
1answer
47 views

Wordpress theme doesn't read my translations from pt_BR.po file

I used PoEdit to create my .pot file. Added some translations, then created a .po file alongside with automatically created .mo file. My .po file looks like this: msgid "" msgstr "" "Project-Id-...
0
votes
0answers
16 views

How to translate strings in comment form?

How to translate strings in comment form? I need to change string "Název" to "Jméno" and "Email" to "Emailová adresa". I didn't found this strings in .po files.
0
votes
0answers
12 views

Unable to translate with pot file Azuma Child theme

I have looked for a lot of information and I need to ask here because I'm not able to translate my child theme in Wordpress. I installed Azuma Theme (Free version) and, after it, I installed their ...
0
votes
0answers
26 views

Theme translates the_author_posts_link. How can I remove their translation?

My theme (Avada) translates the function the_author_posts_link to add “By ” before the author’s name (see their code below). I don't want “By ” before the author’s name. How can I override this ...
0
votes
0answers
18 views

Woocommerce: “is a required field” not translated

I have this problem from a long time and more than a theme. I now have this site build with storefront and the string “is a required field” given in error messages in checkout is not trnslated. ...
0
votes
1answer
464 views

Locale changed but plugin still showing default language

I'm changing the locale using the locale filter. I've tried various methods; creating a plugin and hooking into filter, declaring locale filter hook in the functions.php file, and even as simply as ...
0
votes
2answers
618 views

Language files are not loaded in production

I made changes to my website and it became multilingual locally. I'm using qTranslate-X plugin. I deal with PT and EN. I used __() and _e() functions for strings and POEdit for creating .po and .mo ...
3
votes
2answers
3k views

why is translation not working on theme?

Background I am using the theme Rookie from Sportpress. I created a child theme. Translation files are existing, especially german in my case. Wordpress is set to german language. The Problem ...
1
vote
1answer
513 views

Translate pages and URLs without duplicating

I would really appreciate some suggestions about what plugin to use in WP with DIVI editor, to translate my web site and following these specs: do not duplicate pages (that's really important) ...
17
votes
6answers
19k views

Theme localization of “slugs” (custom post types, taxonomies)

in my theme I want to define a series of custom post types and custom taxonomies, each one having its own customized slug; the base language of my theme is english, therefore the slugs will be in ...
1
vote
1answer
837 views

How can you locate the .po file used for translation of a page?

I'm trying to translate a plugin, Dokan Pro, but I can't seem to find the correct .po file that my Wordpress site is using to translate. Part of it is already translated in Italian, but other parts ...
1
vote
1answer
531 views

Set parent theme language with custom .mo files

I am using Buttercream as my parent theme. I have translated the .mo file located in themes\buttercream\languages and saved it as nl_NL.mo and nl_NL.po. Now I want to display the parent theme in Dutch ...
0
votes
1answer
38 views

How to change WordPress core language using Loco Translate?

I just want to change the text "Add Media" to another English text. I search the text under my theme but it didn't appear. But under Loco Translate > WordPress, there're so many translation files. ...
1
vote
1answer
20 views

Translation Issue with Wordpress Theme Check in comment_form function

I ended my wordpress theme, which called the_mdttheme. I tried to check it and get two errors with translation in comment_form(). Can't understand what did wrong, can someone help me? Here is two ...
1
vote
1answer
2k views

Replace text string on individual page

I am looking to replace a few text strings for only two specific pages on a wordpress site. It should not affect those strings on any other pages. I'd prefer to do this via adding some code to ...
1
vote
0answers
20 views

Wordpress if (is_page) translation on certain page

Hy there i have the following code for custom translations there are missing. function translate_text( $translated ) { $translated = str_ireplace( 'All Ratings', 'Alle Bewertug', $translated ); $...
2
votes
2answers
622 views

Translation of plugin in MU-PLUGINS directory not working

I have successfully translated a child theme, but not the same result in mu-plugins folder. The name of the plugin is "mu-functions.php". In this file I have added the "Text Domain: mu-functions" in ...
2
votes
3answers
6k views

How to tell a theme to use different .mo and .po files?

I have a theme which loads .po and .mo files to display strings in English. I want to have only one language (Polish), but those two files are en_US. I tried replacing content in the en_US.po file but ...
-1
votes
1answer
570 views

Gtranslate function with custom menu

I am very newbie with WordPress and editing plugins. I have a custom menu (English, Chinese (Simplified)) using HTML that I want it to call the gtranslate function for each language but it seems like ...
2
votes
1answer
1k views

Wordpress different language footer text

I am new to WordPress, and I have a problem building my website. I use the Sydney theme and Polylang plugin for my multilanguage website. I have build a website in 4 different languages and now I ...
1
vote
2answers
2k views

How to edit T&C checker text in Woocommerce checkout page? gettext?

I'm trying to edit wording in terms & conditions checkbox on checkout page (order review section), but without luck. It was easy to edit other fields like billing and shipping fields. But I'm not ...
0
votes
1answer
472 views

Translating form labels shortcode output

I'm using MyMail plugin to manage my newsletter. I'm also using WPML to manage translations, there is no compatibility between the two plugins. The subscription form, is placed in the footer area, ...
1
vote
2answers
69 views

Some translations do not work in my template class

I am struggling with the translations of my theme. I use the function get_permalink_date of my class. The relevant snippet is: $permalink_title = sprintf( /* translators: 1 = Post Title, 2 = ...
0
votes
1answer
544 views

Load textdomain from global languages directory

I am creating translations for my plugin. To fetch .mo files from my-plugin/languages directory , I use the function //Load translation function load_plugin_textdomain() { load_plugin_textdomain( ...
1
vote
1answer
818 views

Two text domains in one plugin

From start: A = main plugin(the library), B = child plugin I develop a plugin B that will depend on another plugin A in order to work properly. I do this because I'm one of the persons who don't ...
0
votes
1answer
1k views

Plugin translation not being displayed

I'd like to change some translatable text of a plugin I'm using, Buddypress Group Email Subscription. The text is: No Email (users will read this group on the web - good for any group - the default), ...
0
votes
1answer
671 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 ...
0
votes
0answers
52 views

change text of product id

:D with this code how aply changes only a product id? //Textos traducidos a medida add_filter( 'gettext', 'wps_translate_words_array' ); add_filter( 'ngettext', 'wps_translate_words_array' ); ...
0
votes
1answer
17 views

Which escaping function should be use on register_post_type label?

If I register a post type then which escaping should I use for escaping label? function book_setup_post_type() { $args = array( 'public' => true, 'label' => __( '...
0
votes
0answers
24 views

Remove Home page slug in translated pages

I'm building a website in wordpress, and i've decided to use a custom page "home" for my website's home. I know that i could use the index.php file for the home page , but i needed to use some plugins....
0
votes
1answer
43 views

How to become a translator on wordpress.org?

I tried to find the solution on WordPress.org, but to me as a new contributer, the documentation seems confusing, and links like "Become an editor." in the "Translation Editors" on a plugin's ...
4
votes
2answers
2k views

custom theme: english .mo file not working

I'm having an issue with a .mo file. I have a fully functioning localized custom theme that's running in four languages for the moment: Dutch, English, French and Spanish. There is one problem: the ...

1
2 3 4 5
11