- This topic has 5 replies, 2 voices, and was last updated 2 years, 1 month ago by .
-
Topic
-
I use code below for cloneable text field (and clone_as_multiple!). So when I put in a field html code like
<a href="">
and the press Update post, the field just disappears.When I fill several fields with code like
<a href="">
and press Update post several times then disappears only one by one field.function your_prefix_get_meta_box( $meta_boxes ) { $prefix = 'prefix-'; $meta_boxes[] = array( 'id' => 'untitled', 'title' => esc_html__( 'Untitled Metabox', 'metabox-online-generator' ), 'post_types' => array('d' ), 'context' => 'advanced', 'priority' => 'default', 'autosave' => 'false', 'fields' => array( array( 'id' => $prefix . 'text_1', 'type' => 'text', 'name' => esc_html__( 'Text', 'metabox-online-generator' ), 'clone' => 'true', 'clone_as_multiple' => true, ), ), ); return $meta_boxes; } add_filter( 'rwmb_meta_boxes', 'your_prefix_get_meta_box' );
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- You must be logged in to reply to this topic.