Skip Navigation

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: Asia/Yerevan (GMT+04:00)

Tagged: 

This topic contains 33 replies, has 2 voices.

Last updated by Christopher Amirian 1 year, 2 months ago.

Assisted by: Christopher Amirian.

Author Posts
November 3, 2022 at 9:43 pm

John-Pierre Cornelissen

Hello,

I made a few changes to this source page in Dutch:
hidden link

* Issue 1 *

Now I want to also add that change to the translated pages, but when I go to the (classic) translation editor, all paragraph breaks are gone from the translations. So for example this English translation still shows paragraph breaks on the translated published page, but these paragraph breaks are not in the editor anymore.
hidden link

Attached two images that show the issue
- Paragraph Issue - Published.jpg
- Paragraph Issue - Translation Editor.jpg
- Also see this video screen grab: hidden link

This issue also happens for the French and German translations.

Why did this happen and How can it be fixed without manually adding the paragraphs breaks?

---

* Issue 2 *

Then there is a second issue that I keep seeing on this and other websites. When I go into the translation editor, there is often an empty content item that requires a translation. The only way to mark that as complete is switch to the text tab, add a space, switch back to the visual tab and mark as complete. However, when I save the translation close the editor and go back into the editor, it requires to be 'translated' again. See attached screen shot:
- Empty content.jpg
- Also in the video starting @ 1:47

How to fix this so it doesn't happen anymore

Thanks
JP

Paragraph Issue - Translation Editor.jpg
Paragraph Issue - Published.jpg
Empty content.jpg
November 7, 2022 at 1:00 pm #12400033

Christopher Amirian
Supporter

Languages: English (English )

Timezone: Asia/Yerevan (GMT+04:00)

Hi JP,

There are a few steps I need you to do before being able to dive deeper into the issue.

First, please update WPML to version 4.5.13 and String Translation to 3.2.3

- IMPORTANT STEP! Create a backup of your website.
- Go to "WordPress Dashboard > Plugins > Add new > Commercial (tab)".
- Update WPML and its addons there.

For more information:
https://wpml.org/faq/install-wpml/#automated-updates

After that please install this plugin and activate it:

https://wordpress.org/plugins/enable-jquery-migrate-helper/

Then do as follows:

- Go to your Dashboard > Pages.
- Open the edit screen of the original page. You should see a pencil/circle/gear icon in the sidebar options under Languages section.
- Make a small change, for example, add an extra blank space at the end of a sentence/paragraph.
- Save it.
- You should now see that a circular arrow appears beside the 2nd languages links, this means that an update is required.
- Edit the translation again and save it up to 100% translated.

See if it fixes the issue that you are experiencing.

Thanks.

November 7, 2022 at 9:24 pm #12403917

John-Pierre Cornelissen

Hi Christopher,

Thank you. I did what you asked, except for the last thing 'saving the translation'.

Reason is as I explained. The published translated content HAS paragraphs breaks, but the translation editor doesn't see them anymore. If I save the translations now without the paragraph breaks, they are gone forever.

So I need a fix for the classic editor so it keeps the paragraph breaks just like they were saved and published before.

- and then there is also the second issue.

Thanks
JP

November 8, 2022 at 2:18 pm #12411245

Christopher Amirian
Supporter

Languages: English (English )

Timezone: Asia/Yerevan (GMT+04:00)

Hi there,

We will need to check this further and for that, there is a need for the staging version of your website so that we can test things out there.

Please contact your hosting service provider and ask them to create a copy of the website and get back to us with the URL/Iser/Pass and FTP info

Also please make sure you set the next reply as private.

Also, if you want to finish the last step to see if the paragraph issue really is translated to the front end or not, you can install the plugin below and copy your page to a new page and do the test completely and get back to us:

https://wordpress.org/plugins/duplicate-post/

Thanks.

November 9, 2022 at 12:21 pm
November 9, 2022 at 1:37 pm #12420595

Christopher Amirian
Supporter

Languages: English (English )

Timezone: Asia/Yerevan (GMT+04:00)

Hi there,

Before being able to check we need to fix the Visual tab empty issue.

That issue will be fixed by installing the plugin below:

https://wordpress.org/plugins/enable-jquery-migrate-helper/

I see that you installed that plugin but it was not enabled. I enabled that plugin and the issue that you mentioned is fixed (The empty Visual Tab problem)

I checked the website and could not find reasons why there is such a behavior.

I suggest that you follow the steps below:

- IMPORTANT STEP! Create a backup of your website.
- Switch to the default theme such as "TwentyTwenty" by going to "WordPress Dashboard > Appearance > themes".
- IMPORTANT STEP! Create a backup of your website.
- Go to "WordPress Dashboard > Plugins" and deactivate all plugins except WPML and its add-ons.

Then do the change and add the paragraph tags in the editor to fix the issue and then monitor the website.

If there is no sign of the issue, enable the plugins one by one to find the one causing the issue with the paragraphs.

I spent a lot of time there and could not find any clue.

I do see an old known issue:

https://wpml.org/errata/visual-text-toggle-removes-paragraph-tags-on-translations-and-shows-on-one-line/

But it is for an older version of WPML and it is about the Elementor plugin and not the Divi builder.

So I think it is not related, but I want to mention that I did a deep dive and could not find any reasons till now.

That is why I ask for such a test to find out what might cause a problem. It might be a plugin or the combinatio of the plugins or the child theme. I am not sure. It needs to be tested by you.

Thank you.

November 9, 2022 at 3:13 pm #12421587

John-Pierre Cornelissen

Thanks.

Can you please elaborate on the jquery helper?

1. Why does the current WPML version need it?
2. The visual tab issue does not exist on the live website (with/without jquery helper). Then why is it an issue on the clones website?

The line break issue might be an old issue that has been fixed by now, because I have already fixed a few pages where this happened, and the issue doesn't return when I edit the source and then update the translations.

Can we see if the Elementor fix also works on Divi? How do I change the code? Is it simply replacing ELEMENTOR_VERSION with DIVI_VERSION?

Thanks

Update: tried that fix with DIVI_VERSION but it results in a critical error.

November 10, 2022 at 8:26 am #12426897

Christopher Amirian
Supporter

Languages: English (English )

Timezone: Asia/Yerevan (GMT+04:00)

Hi there,

Let me explain:

From a version in WordPress, they decided to not include the jQuery Migrate library in the code anymore.

That means, the older codebases needed to be changed completely.

After they released that version, there were a big backlash and many plugins stopped working, then they released that plugin to install to include the jQuery Migrate library for the plugins that have older codebase.

Now, the classic editor uses the TinyMCE WYSIWYG which is an older codebase and it needs that plugin.

It does not show the problem every time, as it depends on the context that is used.

We do recommend that our customers use the Advanced Translation Editor which is a newer codebase, but it is not compatible with the classic editor and the translation should be done from scratch for that.

So you either can continue using Classic Editor with the note that it is legacy and needs that plugin to work with.

----------------------

Now regarding the issue at hand, The problem was only for Elementor and not Divi, but as you say it is not repeating then I think it is safe that you do the change and add the paragraphs for the translations.

Thanks.

November 10, 2022 at 11:47 am #12429171

John-Pierre Cornelissen

Thank you for explaining but I think that's not the whole story.

I have WPML on 17 sites and I never needed to install jquery migrate. Most of these websites use the classic translation editor. On the website with the current issue, the plugin is not needed either. For some reason it was only needed after cloning the website.

And despite the classic editor has old code base, the problem was fixed in an update.
https://wpml.org/changelog/2020/08/fixed-jquery-issues-in-wpml-4-3-19-wcml-4-10-2/

Also in this ticket your colleague said in March 2022 "The plugin jquery migrate should not be required with the latest versions of WPML." https://wpml.org/forums/topic/media-translation-frozen-by-jquery-problem/

So if there still is any context where that jquery migrate plugin is needed, it needs to be fixed.

--

Now back to the issue at hand. I still would like this to be further investigated because I just checked on another website, and it has the same issue. This is even on a page that has no changes and doesn't require a translation update. When I open the editor, it shows all translations without paragraph breaks and the page as 100% translated. So apart from stripping the paragraph breaks, it doesn't even indicate it has changed the translations.

This issue needs to be fixed, because I can't risk that making a small edit causes a full page with multiple paragraphs be saved back as a single paragraph.

I did some further investigation. I went into string translations and searched for this string that has translation issues: (Deze kamer bevindt zich op de tweede verdieping van de Bastide)

When I click the pencil icon there to edit the translation, then I see that the paragraph breaks are still there in the translation (see attached screenshot). So since the actual translation is still in tact, it seems there is an issue with the classic translation editor that strips the paragraph breaks from the translation.

Please have someone investigate this further.

Thanks,
JP

WPML.jpg
November 10, 2022 at 1:55 pm #12430585

Christopher Amirian
Supporter

Languages: English (English )

Timezone: Asia/Yerevan (GMT+04:00)

Hi there,

Thank you for the information. The plugin fixed the issue anyway and after deactivating the plugin the issue does not happen.

So we can focus on the other issue that you are experiencing:

- I already escalated this to the second tier and will ask whatever questions they have along the way.
- I also need to know if there is a common thread between the pages that cause the issue?
- I created a new test page and the issue is not replicable there. So we need to know what is the problem with those old ones.
- Maybe the issue is coming from a specific Divi element? You know better what it might be.
- Please give us as many info as you can so at least ew have a way to go forward.

November 10, 2022 at 2:26 pm #12431031

John-Pierre Cornelissen

Not sure what you are talking about now, but the plugin did *not* fix the paragraph issue. So that still needs to be investigated.

For the other issue with the et_pb_image:content I have created a separate ticket. I figured it's better that way to not mix different issues.

November 10, 2022 at 2:49 pm #12431481

Christopher Amirian
Supporter

Languages: English (English )

Timezone: Asia/Yerevan (GMT+04:00)

Ok it seems that you misunderstood.

Please forget the plugin. The plugin was for the Visual tab issue that it is fixed already so forget it.

I am now talking about the paragraph issue and I expect to have answers to the questions below to be able to continue to help:

- I already escalated this to the second tier and will ask whatever questions they have along the way.
- I also need to know if there is a common thread between the pages that cause the issue?
- I created a new test page and the issue is not replicable there. So we need to know what is the problem with those old ones.
- Maybe the issue is coming from a specific Divi element? You know better what it might be.
- Please give us as many info as you can so at least we have a way to go forward.

Thanks.

November 10, 2022 at 3:19 pm #12431963

John-Pierre Cornelissen

Ok, sorry for the confusion

I also need to know if there is a common thread between the pages that cause the issue?
» The only thing I think of is that these are 'old' translations. I saw it happen on old pages that were created and translated back in 2018 as well as newer pages from April 2022. When I do a new translation now, the problem does not occur.

I created a new test page and the issue is not replicable there. So we need to know what is the problem with those old ones.
» Exactly, that's were your support and expertise with WPML comes in.

Maybe the issue is coming from a specific Divi element? You know better what it might be.
» I have noticed it with text modules, but I think it happens with every module that has a text area with tinymc

Please give us as many info as you can so at least we have a way to go forward.
» I can't think of anything else, except that the string editor shows the correct translations with the paragraph break and that the paragraph breaks are gone when they are loaded in the classic editor. I'd like to think that's a pretty good point to start with. Can't you add a trace or logging that shows exactly what's happening there?

If you need I can generate a report with all updates that have been installed in the past year.

Thanks

November 12, 2022 at 6:40 am #12443583

Christopher Amirian
Supporter

Languages: English (English )

Timezone: Asia/Yerevan (GMT+04:00)

Hi there,

Thank you for the replies, I updated the second tier with the information that you provided.

The initial recommendation is indeed that the error below might be bleeding over to Divi too:

https://wpml.org/errata/visual-text-toggle-removes-paragraph-tags-on-translations-and-shows-on-one-line/

That is why the second tier asked me to check the solution.

I tried to add the proper code to functions.php of the child theme in the staging website but it seems to have an issue and now the site is down.

Would you please give us also the FTP access to the staging website?

We want to rename the theme folder to make sure the dashboard is available and test by adding the code directly to the theme files via ftp.

You can set the next reply as private to give the ftp info.

Thank you.

November 12, 2022 at 10:01 am

The topic ‘[Closed] Paragraph breaks removed from translations’ is closed to new replies.