I believe the problem is with your use of sanitize_text_field
(line 668 in your pastebin), which will strip markup. Proof of concept:
$str="<p>Howdy Ho!</p>";
echo $str;
echo sanitize_text_field($str);
You will need to use some other function to clean the data… possibly wp_kses
Related Posts:
- Save metabox with multiple checkbox array
- How to add tab which is visible only in admin side of product in woocommerce? [closed]
- How to create Image gallery Metabox in wordpress [closed]
- Best choice of options/settings framework for plugin/theme development
- Ordering posts by metadata
- update post meta for checkbox in the admin when inserted in the front-end
- Custom Taxonomy to dropdown box on adminside wordpress
- Create & Save multiple Meta-boxes
- Saving value of a selection option in comment form as comment meta
- Add a Save Button to Custom Meta Box [duplicate]
- How to get Metabox custom field to show checked if value is updated using post meta query?
- How do I update a field of a meta box?
- Input value from metabox is not found in $_POST after post save
- Run Shortcode of post’s custom field in functions.php / Plugin
- WP nonce field checkbox prints checked=’checked’ outside input field
- Issues Updating Post Meta with AJAX (Seems simple but cannot figure it out)
- Adjust query on single
- Why is $_POST empty when saving custom Meta Box?
- add_meta_box does not display meta box in Admin
- Displaying Custom Post Meta
- How can you include custom post meta in search without calling each key?
- Custom fields for custom post type
- Display Custom Meta Box Field Only If Value is Present
- How to add a widget to the post editing view?
- Checked() function on a multidimensional array
- shortcode in a custom metabox
- What is the best way to store a few fields?
- Delist entries in the_loop
- Adding admin menus to wordpress
- Remove entire [$key] from array stored in custom field using Ajax – unset($array[$key]); not working
- How can I add a simple custom field to my plugin?
- Ajax is not working in a loop
- How to I retrieve the ID from the Posts page?
- create custom meta box with default value
- Problem with saving large amount of data in postmeta/usermeta
- Automating the process of shortcode generation in a plugin – how is it done?
- Move Title and the Content WYSIWYG editor position
- How to validate select field in post meta?
- How to use media upload on metabox post page without breaking TinyMCE?
- Meta box on options page save form problem
- Let’s Create Custom Field Template Documentation
- Moving/dragging a metabox removes TinyMCE’s content
- Store custom meta box data as serialized array
- Ajax: Populate with content from a post’s ID not working – duplicating current page html instead
- How to save post meta as an array in Gutenberg?
- Adding custom meta boxes to specified custom post type
- per blog metadata for plugin
- How add multiple wp_editor_box to new post
- How to store multiple custom meta box
- How to add custom post widgets as tags into wordpress
- How to format custom fields when editing an attachment?
- Using delete_post_meta for deleting multiple selected options
- Can I save post meta programatically without setting metaboxes?
- How can I output WPAlchemy repeating fields meta values in my page template?
- Get audio metadata on file upload
- Plugin can’t be activated [closed]
- Meta box values are displayed on Custom Fields list. Is it possible to hide them?
- If metabox has content display content
- put saved metabox values back into fields and then display on the front end
- Add a class to post_class if more than one post shares same meta_value_num
- Add a meta field to the list of results for a custom post type
- Remove Meta-boxes (Yoast SEO plugin) [duplicate]
- Empty meta-box returns publishdate if no value is set?
- Is there a way to add a link with add_post_meta?
- Can I attach a plugin via my add_filter callback contents?
- Custom Meta Data is not being saved
- how to add custom fields into new & update post page?
- Metabox is not displaying
- Catch metabox values in Plugin
- want to show CMB2 metabox on woocommerce product data tab
- Customise Grouped Product display in Woocommerce with custom column
- Custom Post Type meta data getting deleted on bulk editing taxonomies
- WP_List_Table Inside Metabox With Bulk Actions Not Working on Submit
- Condition to check previous next article post title
- How to improve my non-unique metadata MySQL entries?
- register_meta not showing custom post type metabox data in rest api
- Set class if a meta value is set within post archive
- WP_Query not ordering correctly
- Unable to gather Image URL from Custom Post Type’s; Custom Meta Field
- Adding customs fields on each product on the cart
- Insert, update or remove data from database (usermeta)
- Save meta box data from selected dropdown list in bbpress reply form
- Metabox types list
- WordPress Blocks, setAttributes not saving
- WordPress Filesystem create CSS-File – get Shortcode ID for Name
- Allow HTML in Custom Metabox area
- How to save multiple values in custom post type from front end to back end
- Add WordPress Meta Box saved form input to WordPress RSS feed [duplicate]
- Custom field metabox not showing in back-end
- Creating a “Related Meta” type field?
- set a custom post type to a taxonomy term programmatically in metabox
- Unexpected issue when using attachment_fields_to_edit filter
- Save, update, get and sanitize post meta as HTML not plain
- WordPress delete mysql rows with string
- How to get post that has non zero or greater than zero meta value
- Dynamically getting tags in post edit screen
- Saving post meta
- How and when would I implement some code which would take data from one part of the Db and put it in another?
- Create Meta boxes dynamically
- How to show metabox just in post.php in admin?