Category extra description – paragraphs are removed
-
Hello,
I edited the attached text for a category page extra description via an HTML block. In the edit view and preview of the HTML block everything looks fine and as desired:
Attachment SCR-20231022-sxoa-2.png or https://shottr.cc/s/WZYh/SCR-20231022-v9x.png
But in the view of the customer the frontend is shown without any paragraphs / looks like all paragraphs are removed.
Attachment SCR-20231022-sxoa.png or https://shottr.cc/s/W3al/SCR-20231022-vcq.png
I also tried to add <p> tags in the code view manually but they are stripped after saving.
Can you please help me or let me know what more information you need?
Thanks in advance
-
This topic was modified 1 year, 8 months ago by
Pala2023.
-
This topic was modified 1 year, 8 months ago by
Pala2023.
Attachments:
You must be
logged in to view attached files.
Hello,
Could you please check how it works with some default WordPress themes like TwentyTwenty or WooCommerce Storefront to understand is it our theme issue or not?
Kind Regards
Hello,
I fixed it by myself after googling some more stuff.
Added this to the functions.php and now the p-Tags are no more stripped out.
foreach ( array( 'pre_term_description' ) as $filter ) {
remove_filter( $filter, 'wp_filter_kses' );
}
foreach ( array( 'term_description' ) as $filter ) {
remove_filter( $filter, 'wp_kses_data' );
}
Hello,
Glad that you have fixed that.
In case you need any additional help, I’d be more than happy to assist you.
Have a good day!
Kind Regards
The topic ‘Category extra description – paragraphs are removed’ is closed to new replies.