I am using tinymce 4.0.1 and it automatically adds p tags when you either start typing or hit enter. How can I dynamically remove these p tags and then reinsert the content into the editor.
Tinymce needs a root block element, which is a paragraph by default, in order to be able to style content. So removing those paragraphs will only result in all content being wrapped into one single paragraph because tinymce is forced to use this as root block element.