I am copying text from any of the sources like MS word, Open office writer or from any website and paste it in the rich text editor. But after pasting it in the website, we want to remove all the styles except bold, Italic and underline. Below is the sample code which I have tried to achieve it but it's still not in case of h1,h2,h3 and so on. Please suggest how to achieve it. Thanks in advance.
tinymce.init({
selector : "#job_description",
menubar : false,
statusbar : false,
theme : "modern",
toolbar : "bold italic underline | bullist numlist",
content_css : "resources/css/richTextEditor.css",
plugins: 'paste',
paste_auto_cleanup_on_paste : true,
paste_remove_styles: true,
paste_remove_styles_if_webkit: true,
paste_strip_class_attributes: true
});
richTextEditor.css:-
.mce-item-table {
/*overflow-x:hidden!important;*/
width: auto!important;
}
.mce-content-body span,p{
font-size: 16px!important;
text-decoration: none!important;
color: #858585!important;
font-weight: 400!important;
font-family: 'Roboto', sans-serif !important;
}