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 |
---|---|---|---|---|---|---|
- | 8:00 – 12:00 | 8:00 – 12:00 | 8:00 – 12:00 | 8:00 – 12:00 | 8:00 – 12:00 | - |
- | 13:00 – 17:00 | 13:00 – 17:00 | 13:00 – 17:00 | 13:00 – 17:00 | 13:00 – 17:00 | - |
Supporter timezone: Asia/Ho_Chi_Minh (GMT+07:00)
Tagged: Documentation request
This topic contains 22 replies, has 3 voices.
Last updated by Long Nguyen 1 year, 3 months ago.
Assisted by: Long Nguyen.
Author | Posts |
---|---|
January 29, 2024 at 5:26 pm #15240091 | |
anneR-12 |
Tell us what you are trying to do? Trying to translate the featured image and in-post images. Asked to do in in two places. How can I do this more efficiently? Is there any documentation that you are following? Is there a similar example that we can see? What is the link to your site? hidden link |
January 30, 2024 at 9:15 am #15242166 | |
Sumit Supporter
Languages: English (English ) Timezone: Asia/Kolkata (GMT+05:30) |
Hi, Thank you for contacting the support forum. The one that is coming from Kadence/image is not needed. This is a custom block from the plugin I guess so WPML is not aware of the content type and what needs to be translated. We can define custom XML configuration for the blocks. See this article https://wpml.org/documentation/support/language-configuration-files/make-custom-gutenberg-blocks-translatable/ Then we can exclude the images. Another option is ATE. If you use ATE to translate the pages, ATE can filter the strings from HTML and use translation memory so you have to translate one string only one time no matter how many times that string is repeated on the website. I would recommend to use ATE https://wpml.org/documentation/translating-your-contents/advanced-translation-editor/ Thanks |
January 30, 2024 at 1:08 pm #15243899 | |
anneR-12 |
Hi Sumit, Thanks for getting back to me. You say that the translation coming from Kadence/image is not needed, however when I translate the images both the media section and the Kadence image block (I am required to translate both before I can publish the translation), it is the translation from the Kadence image block that is shown on the front end. The translation I set in the media section is only used for the featured image. I do not want to use the advanced translation editor. I don't want auto generated translations and when I tried it, I seemed to be obliged to have a translation for every sentence in the original language (which doest work for me when something can be better written in only one sentence in the second language). So that would leave me with your first suggestion. I went through the documentation, but it is not clear to me what code I should use to ''exclude images'' so that I only be prompted to translate them in the media section. What code would it be? Should I just replace the 1 by a 0 as such: Example of settings for translation of Gutenberg block Will that still allow me to translate in the images from the media section? Thank you, |
January 31, 2024 at 4:32 am #15247206 | |
Long Nguyen WPML Supporter since 02/2022
Languages: English (English ) Timezone: Asia/Ho_Chi_Minh (GMT+07:00) |
Hi Anne, Please notice the block type in the XML configuration code. It should be "kadence/image" instead of "core/image". For example: <wpml-config> <gutenberg-blocks> <gutenberg-block type="kadence/image" translate="0"> </gutenberg-block> </gutenberg-blocks> </wpml-config> then you can translate the image information only. Look forward to your reply. |
February 2, 2024 at 12:15 am #15257244 | |
anneR-12 |
Hi, I inserted the code, but it did not change anything. When I try to translate a post, I am still asked to translate images both in the MEDIA section and the PAGE BUILDER section. Anne |
February 2, 2024 at 1:51 am #15257301 | |
Long Nguyen WPML Supporter since 02/2022
Languages: English (English ) Timezone: Asia/Ho_Chi_Minh (GMT+07:00) |
Hi, I would like to request temporary access (wp-admin and FTP) to your site to take a better look at the issue. It would be better to have a testing site where the issue is replicated. Your next reply is set to private to share the info. ❌ IMPORTANT: Please backup your database and website before proceeding ❌ Look forward to your reply. |
February 2, 2024 at 3:51 am #15257448 | |
Long Nguyen WPML Supporter since 02/2022
Languages: English (English ) Timezone: Asia/Ho_Chi_Minh (GMT+07:00) |
Hi, I add the custom XML configuration code to WPML > Settings > Custom XML Configuration. Then edit the page in English > Click on Update > Visit the WPML Translation Editor and now the block "kadence/image" content isn't available there. Can you please recheck this? <wpml-config> <gutenberg-blocks> <gutenberg-block type="kadence/image" translate="0"> </gutenberg-block> </gutenberg-blocks> </wpml-config> Refer documentation Look forward to your reply. |
February 2, 2024 at 12:03 pm #15258977 | |
anneR-12 |
Hi Long, To edit a post, I go to: > Posts In the translation for the posts, There is a media section with all the images. Then underneath it there is a Page Builder section which has all kadence block images (so all the images are repeated, except for the featured image). In other to save and close the translation and for it to be published, I need to fill out ALL the section, so do each image twice. |
February 2, 2024 at 12:12 pm #15259192 | |
anneR-12 |
Apologies, the Kadence imge section does disappear when I update the English version first. But, when I set an alt text in the translation, it does not appear on the front end (I use the Chrome extension Image Alt Text Viewer to see alt texts on a page, but there are other tools that do it too). For example in article hidden link The photo under subsection 2 is still showing in English, despite me having set it to be: Bataille Royale est un événement à Québec en mars in the translation tool. So it's still not working for me, in fact I can't seem to translate in-post image alt text anymore. How can I fix that? |
February 3, 2024 at 12:03 pm #15262025 | |
anneR-12 |
Hi, I just wanted to follow-up on this. Is it possible to have live support? |
February 5, 2024 at 3:33 am #15264164 | |
Long Nguyen WPML Supporter since 02/2022
Languages: English (English ) Timezone: Asia/Ho_Chi_Minh (GMT+07:00) |
Hi, Sorry for the late reply, we don't work at the weekend. The problem is, the Kadence block image uses its own alt text (block settings), which is separated from the image alt text of the image so I'm afraid that you will need to translate the block content as in your first comment. Or follow the suggestion from my colleague to use the Advanced Translation Editor to prevent translating one sentence multiple times. If you want to translate multiple sentences from the original language into one sentence in a second language, you can use the option join sentence. Please follow the documentation https://wpml.org/documentation/translating-your-contents/advanced-translation-editor/#joining-sentences If you want to have live support, please open a new chat session https://wpml.org/forums/forum/english-support/ Look forward to your reply. |
February 5, 2024 at 7:13 pm #15268195 | |
anneR-12 |
Hi Long, Alright, so I've tried the advanced Editor. On my home page, the alt text are not appearing in French on the front end, despite me translating them in the advanced editor. See attached screenshot vs url: hidden link What is the issue in this case? Thank you, |
February 6, 2024 at 1:59 am #15268693 | |
Long Nguyen WPML Supporter since 02/2022
Languages: English (English ) Timezone: Asia/Ho_Chi_Minh (GMT+07:00) |
Hi, Because the block content "kadence/image" is excluded from translating with the XML configuration code above https://wpml.org/forums/topic/why-am-i-asked-to-translate-each-image-twice/#post-15257448 Look forward to your reply. |
February 9, 2024 at 7:59 pm #15287453 | |
anneR-12 |
Hi Long, Really keen to hear your suggestions to fix that. Thank you, |
February 9, 2024 at 8:32 pm #15287527 | |
anneR-12 |
Let me give an example for us to work with: URL: hidden link Note that Kadence suggested I turn ON the dynamic alt-text toggle on the post (see second screenshot). This makes the image alt text be defined at the Media level rather than the block level. Thank you, |
The topic ‘[Closed] Why am I asked to translate each image twice’ is closed to new replies.