Skip Navigation

[Resolved] WYSIWYG post field, line breaks missing

This support ticket is created 5 years, 5 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

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: America/New_York (GMT-04:00)

This topic contains 4 replies, has 2 voices.

Last updated by Christian Cox 5 years, 5 months ago.

Assisted by: Christian Cox.

Author
Posts
#1162086

Hello!

I cannot figure out why, but line breaks that were inserted into WYSIWYG post fields are being ignored / erased. Interesting thing is, that the content displays correctly in one location (with breaks), and incorrectly (without breaks) in others on the same page / template. Both views are set the exact same way?

Thanks!

#1162450

Hi, it depends on several factors that vary by theme and can be affected by other 3rd-party plugins. You can try adding suppress_filters="true" to the WYSIWYG field shortcode:
https://toolset.com/documentation/customizing-sites-using-php/functions/#wysiwyg

You can also try wrapping the WYSIWYG field in a wpv-autop shortcode:
https://toolset.com/documentation/user-guides/views-shortcodes/#vf-325519

Then you can try doing both at the same time. If none of these seems to work, I'll be glad to take a closer look.

#1165684

Unfortunately even with both of these methods in play, if any edit is done to the post (can be other fields in the post and not the problem field), the line breaks are removed.

#1165762

May I log in to see the problem? Let me know where I can find the WYSIWYG field.

#1167878

I made an adjustment in the Campus View. I added the auto paragraph shortcode and removed the suppress_filters attribute:

<div class="text-white center">[wpv-autop][types field='campus-service-times'][/types][/wpv-autop]</div>

Now the line breaks in the campus service time field are respected on the front-end of the site in both places. I edited the Campus and changed some text, and the line breaks seem to be preserved. Can you confirm?
hidden link

This ticket is now closed. If you're a Toolset client and need related help, please open a new support ticket.