This is the technical support forum for WPML - the multilingual WordPress plugin.
Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.
Sun | Mon | Tue | Wed | Thu | Fri | Sat |
---|---|---|---|---|---|---|
- | - | 9:00 – 18:00 | 9:00 – 18:00 | 9:00 – 18:00 | 9:00 – 18:00 | 9:00 – 18:00 |
- | - | - | - | - | - | - |
Supporter timezone: America/Lima (GMT-05:00)
This topic contains 3 replies, has 1 voice.
Last updated by Andreas W. 1 week ago.
Assisted by: Andreas W..
Author | Posts |
---|---|
January 20, 2025 at 5:44 pm #16615083 | |
emmanuelleD-4 |
Background of the issue: Symptoms: Questions: |
January 22, 2025 at 7:38 am #16621314 | |
Waqas Bin Hasan Supporter
Languages: English (English ) Timezone: Asia/Karachi (GMT+05:00) |
Hi, Thank you for contacting the support. Meanwhile this ticket is attended by one of my colleagues, please note that the said plugin "WPdiscuz" isn't on our compatibility list and you may experience such issues. However, I'll recommend checking our guide https://wpml.org/documentation/getting-started-guide/string-translation/finding-strings-that-dont-appear-on-the-string-translation-page/ about other methods when strings are not available for translation. Specially see the sections about "Scanning the Theme or Plugin" and "Translating Strings From Admin and Settings". Further, you may need to check with the said plugin support for a compatibility updates. Please feel free to share your findings and we'll try our best to help you further on the matter. Regards. |
January 22, 2025 at 10:23 pm #16625173 | |
emmanuelleD-4 |
Hi Waqas, Thank you for your response. I have tried all methods but nothing seems to pick up the items to be translated. The only one I find is the "post comment" button which I have translated but the translation still doesn't show. Things like the title "leave a review" is added through CSS so I find it odd this doesn't get picked up either when scanning the theme. I can find all items related to the plugin itself in the string translations such as error messages, etc. but the actual items from the comment section visible on the front end aren't picked up. Is there a workaround? Many thanks in anticipation, Emma |
January 25, 2025 at 7:26 pm #16633914 | |
Andreas W. Supporter Languages: English (English ) Spanish (Español ) German (Deutsch ) Timezone: America/Lima (GMT-05:00) |
Hello, Please take note that I ran a quick test with WPdiscuz and the languages English, German and French and the strings for the plugin were automatically translated as this plugin already comes with pre-defined translations. --- To alter those default translations you will first need to register the strings. Go to WPML > String Translation and enable the option to auto-register strings for translation: " Look for strings while pages are rendered" which is located in the bottom section of the page. Then go to one of your posts on the Frontend. If you already have a post open, please refresh the browser. This will auto-register the strings. The string will be registered inside the text domain "wpdiscuz". You can use the text-domain filter on WPML > String Translation to locate them. On my test 244 strings were found. --- The issue: When trying to translate the string "Join the discussion" or the "Post comment" button I can confirm that the translations from WPML > String Translation are not showing up on Frontend. The reason for this might be the way in which those strings are displayed on the comment forms, which means if the translation does not show up, then this is likely related to how WPdiscuz is coded and if it would be coded to WordPress standards, then the translation should work as expected. Taking a closer look into the plugin, I can confirm that for example the string "Post Comment" is called not only once inside the plugin, it is called three times, while on WPML String Translation we see it only once. Example: ... $formStructure["right"][wpdFormConst::WPDISCUZ_FORMS_SUBMIT_FIELD]["name"] = isset($phrases["wc_submit_text"]) ? $phrases["wc_submit_text"] : esc_html__("Post Comment", "wpdiscuz"); ... \wpdiscuz.7.6.27\wpdiscuz\forms\wpdFormAttr\Form.php ... wpdFormConst::WPDISCUZ_FORMS_SUBMIT_FIELD => [ "type" => "wpdFormAttr\Field\DefaultField\Submit", "name" => esc_html__("Post Comment", "wpdiscuz") ], ... \wpdiscuz.7.6.27\wpdiscuz\forms\wpdFormAttr\Field\DefaultField\Submit.php ... protected function initDefaultData() { $this->fieldDefaultData = [ "name" => esc_html__("Post Comment", "wpdiscuz"), ]; } ... I am not sure why the plugin is registering the same string more than once and why can not capture all of these strings, but this would need further testing. Possible Causes: Incorrect String Registration: WPML is not capturing all instances of the string because the plugin code might not be fully aligned with WPML's standards for string registration. This means we are likely not translating the correct string. I went to WPML > Theme & Plugin Localization and scanned the entire WPdiscuz plugin for new strings but even after that, I can only find the string "Post Comment" once on WPML > String Translation. As I mentioned earlier, this issue might arise, due to the way how the plugin is coded and the plugin might need code adjustments to make it work properly with WPML String Translation. I then went to the support channel of WPdiscuz and did a quick research and it seems as if they are explaining that translating the plugin will only be possible by using the language files that come with the plugin. We have been trying to reach out to GVectors (the makers of WPDiscuz) about 7 months ago in order to obtain a partnership, but we have not obtained any cooperation yet. At this point, the only thing I can offer is to escalate the issue to our compatibility team, which might then again try to reach GVectors and try to solve those issues with them together. Anyhow, I think it might be better if you first reach out to the support of WPdiscuz, explain the issue, and get a second opinion from them. If there are no plans from their side to make the plugin compatible with WPML, then there might be nothing we can do from our end. In case the author is interested in starting a partnership with WPML so that we can give support in making the plugin compatible with WPML, then the author can fill out the following form: In case the author will not cooperate, please reach out to us again, so that we can try to find a workaround for the issue. Best regards |