I am recently working on a project that enables users to submit content from frontend.
Since I am using
wp_editor() to display the editor, I find it a little bit of confused how to correctly save the input content.
StackExchange user Sam posted a solution in a thread. It just works perfect.
WordPress keeps track of what kind of editor (visual or html) is active as a class which is added to the content wrapper so here is a solution that will get you the latest content in the editor.
Remember to replace the
editor_id with your true editor ID parameter defined in