Skip to content Skip to sidebar

This thread is resolved. Here is a description of the problem and solution.

Problem:
The client was experiencing layout changes when switching languages on their website, specifically from Dutch to English on a particular page.

Solution:
We reviewed the page in the Translation Editor and confirmed that the translations were correct. The issue was identified as being caused by HTML output, particularly the use of

<br>

tags that were breaking the layout. We advised the client to open the page with the layout issue directly and switch to the "Text" mode in the affected section to remove all unnecessary HTML formatting. We also provided links to documentation on HTML markers to assist the client in making these changes without breaking the HTML structure.

Please note that this solution might be irrelevant if it's outdated or not applicable to your case. If you're still experiencing issues, we highly recommend checking the related known issues, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. If the problem persists, please open a new support ticket with us.

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.

Tagged: 

This topic contains 8 replies, has 2 voices.

Last updated by RVDB 1 year, 6 months ago.

Assisted by: Marcel.

Author Posts
April 23, 2024 at 11:53 am #15555762

RVDB

Hi Mihai ,

this works perfectly, thnx!

one more issue:

if you, for example on this page: hidden link, switch from Dutch to English the whole page layout 'changes'.

what can i do about that?

thnx in advance,

BR Ronald

April 23, 2024 at 4:26 pm #15557511

Marcel
Supporter

Languages: English (English ) Spanish (Español ) German (Deutsch )

Timezone: Europe/Madrid (GMT+02:00)

Hi Ronald,

the only changes I can see in the layout are inside the content (in the block "On this site, some of it still ‘under construction’...). Can you please confirm that you mean the content part, not the design itself?

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 a testing site where the issue is replicated.

You will find the needed fields for this below the comment area when you log in to leave your next reply. The information you will enter is private which means only you and I can see and have access to it.

Maybe I'll need to replicate your site locally. For this, I’ll need to temporarily install a plugin called “Duplicator” or "All in One WP Migration" on your site. This will allow me to create a copy of your site and your content. Once the problem is resolved I will delete the local site. Let me know if this is ok with you.

IMPORTANT
-Please make a backup of site files and database before providing us access.
-If you do not see the wp-admin/FTP fields this means your post & website login details will be made PUBLIC. DO NOT post your website details unless you see the required wp-admin/FTP fields. If you do not, please ask me to enable the private box. The private box looks like this:
hidden link

Best Regards
Marcel

April 23, 2024 at 6:18 pm #15557804

RVDB

hi Marcel,

you are right!

i mean the content of the textbox.

i also see this on other pages where a normal textline (in the original Dutch site) is divided over several lines after translation to English (by WPML).

MEMORY,

in the picture underneath you see an issue i noticed on my (WPML) support page.
Maybe this is a cause?

thnx in advance,

BR Ronald

Schermafbeelding 2024-04-23 201704.png
April 24, 2024 at 1:03 pm #15560920

Marcel
Supporter

Languages: English (English ) Spanish (Español ) German (Deutsch )

Timezone: Europe/Madrid (GMT+02:00)

Hi Ronald,

Yes, a low memory limit could indeed block the correct updating of a page.

Could you please increase first your WP Memory limit? To do so, add this code to your wp-config.php file to increase the WP memory:

define('WP_MEMORY_LIMIT', '256M'); 

Please paste it just before the line "That's all, stop editing! Happy blogging."

For more information, see here: https://wpml.org/home/minimum-requirements/
Note: WPML requires a minimum WP Memory limit of 128M to function in a minimal environment, which means it operates with a default theme and no other plugins installed.

Best regards,
Marcel

April 29, 2024 at 12:16 pm #15577047

RVDB

Hi Marcel,

The issue has not been resolved after increasing the WP Memory Limit.

See attached picture regarding the change.

Can you please check the issue itself on my site?

if you go to hidden link and then choose for 'also available in English' the content make up changes.

BR Ronald

Schermafbeelding 2024-04-29 140845.png
April 29, 2024 at 1:17 pm #15577323

Marcel
Supporter

Languages: English (English ) Spanish (Español ) German (Deutsch )

Timezone: Europe/Madrid (GMT+02:00)

Hi Ronald,

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 a testing site where the issue is replicated.

You will find the needed fields for this below the comment area when you log in to leave your next reply. The information you will enter is private which means only you and I can see and have access to it.

Maybe I'll need to replicate your site locally. For this, I’ll need to temporarily install a plugin called “Duplicator” or "All in One WP Migration" on your site. This will allow me to create a copy of your site and your content. Once the problem is resolved I will delete the local site. Let me know if this is ok with you.

IMPORTANT
-Please make a backup of site files and database before providing us access.
-If you do not see the wp-admin/FTP fields this means your post & website login details will be made PUBLIC. DO NOT post your website details unless you see the required wp-admin/FTP fields. If you do not, please ask me to enable the private box. The private box looks like this:
hidden link

Best Regards
Marcel

April 30, 2024 at 3:31 pm #15582025

Marcel
Supporter

Languages: English (English ) Spanish (Español ) German (Deutsch )

Timezone: Europe/Madrid (GMT+02:00)

Hi Ronald,

it's not working for me. All URLs from /wp-admin redirects me to hidden link

Can you please check this?

Thanks!

Best Regards
Marcel

May 2, 2024 at 3:27 pm #15588273

Marcel
Supporter

Languages: English (English ) Spanish (Español ) German (Deutsch )

Timezone: Europe/Madrid (GMT+02:00)

Hi Ronald,

I checked the page in the Translation Editor on hidden link and it's all correctly translated.

hidden link
hidden link

The line breaks (like at "some books about hiking") that are breaking the layouts are caused by the HTML output. Same at links like "Scotland May 2023". The Source code loads a "br" HTML Tag before the list:

<span style="color: #00ccff;"><br>
  <a href="<em><u>hidden link</u></em>" target="_blank" rel="noopener" style="color: #00ccff;"><br>
    <span style="text-decoration: underline;">Scotland May 2023</span><br>
  </a><br>
</span>

As best, you open hidden link directly and switch to "Text" in the affected section, where you can remove all the loaded HTML. Currently, it loads all of that "unneeded" formatting: https://pastebin.com/jrp48g5h

Please take care not to break the HTML markers; You can find more info about them here:
https://wpml.org/de/faq/what-are-html-tags/
https://wpml.org/documentation/translating-your-contents/advanced-translation-editor/#html-markers

Best Regards
Marcel

May 9, 2024 at 12:31 pm #15610506

RVDB

thnx Marcel,

was away for a few days but this works!

BR Ronald

Met Vriendelijke Groet,

Ronald van de Buld