WYSYWG editor delets content!
Support › MB Builder › WYSYWG editor delets content!Resolved
- This topic has 2 replies, 2 voices, and was last updated 3 years, 11 months ago by
[email protected].
-
AuthorPosts
-
April 28, 2021 at 6:13 PM #27731
[email protected]
ParticipantThe custom field WYSYWG editor shows a very, very strange behavior: If it used with the plugin Display Posts (https://de.wordpress.org/plugins/display-posts-shortcode/) on a site it delets content when the site is saved. When I use WP Pods to have a WYSYWG editor field on the site the problem does not exist. Is this a bug or a feature of Meta Box? Thanks for your help.
April 29, 2021 at 3:41 PM #27760Long Nguyen
ModeratorHi Andreas,
Thank you for reaching out.
I've installed and activated the plugin Display Posts on my local site. After editing and save a post with a WYSIWYG field, I see the field saves data as well. Please follow the Debugging Information step and see if it works. If it still does not work, please share the code that creates the WYSIWYG field. Using the option "Get PHP Code" https://docs.metabox.io/extensions/meta-box-builder/#getting-php-code, I will check it out.
April 30, 2021 at 8:31 PM #27780[email protected]
ParticipantHi Long,
first of all: Thank you for mentioning Immolist Mallorca in the showcase! And thanks for the quick reply.
- The debugging information does not show any hint what is wrong
- The php code is attached below.
- In a short video you can see whats happens:
https://drive.google.com/file/d/1BLts2zzSQkgMrjrI4ulwO8ovARwwW2MI/view
It seems to be a very rare case. I occurs only when I put the shortcode in the standard content editor of a page. The same shortecode in the custom field works without any problem. It is not a big thing for me since I can build up the site without the shortcode in the standard content editor. Generally I am very happy with Metabox.Kind regards, Andreas
<?php
add_filter( 'rwmb_meta_boxes', 'il_pagefields' );function il_pagefields( $meta_boxes ) {
$prefix = '';$meta_boxes[] = [ 'title' => __( 'PageFields', 'il-mallorca' ), 'id' => 'pagefields', 'post_types' => ['page'], 'priority' => 'low', 'fields' => [ [ 'name' => __( 'Extratext', 'il-mallorca' ), 'id' => $prefix . 'extratext', 'type' => 'wysiwyg', ], [ 'name' => __( 'Schemadata', 'il-mallorca' ), 'id' => $prefix . 'schemadata', 'type' => 'textarea', 'label_description' => __( 'Schema', 'il-mallorca' ), 'save_field' => 1, ], ], ]; return $meta_boxes;
}
-
AuthorPosts
- You must be logged in to reply to this topic.