0
MSワード、Open Officeライター、または任意のWebサイトのいずれかのソースからテキストをコピーしてリッチテキストエディタに貼り付けています。しかし、それをウェブサイトに貼り付けた後、太字、イタリック、アンダーラインを除くすべてのスタイルを削除したいと考えています。以下は、私がそれを達成しようとしたサンプルコードですが、h1、h2、h3などの場合はまだありません。それを達成する方法を提案してください。前もって感謝します。太字、イタリック、アンダーライン以外のすべてのスタイルを削除した後にテキストを貼り付けてください
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;
}