Javascript Ckeditor断页css网页
我使用的是ckeditor,我从数据库中读取一个模板,其中包含html代码css和js 问题是在使用时:Javascript Ckeditor断页css网页,javascript,html,ckeditor,wysiwyg,Javascript,Html,Ckeditor,Wysiwyg,我使用的是ckeditor,我从数据库中读取一个模板,其中包含html代码css和js 问题是在使用时: CKEDITOR.replace ('description'); 模板的css代码与网页的代码合并,然后网页采用我从模板中读取的样式并打破样式 我应该做的是,编辑只接受css,而不是网页 我的配置是: CKEDITOR.editorConfig = function( config ) { config.toolbarGroups = [ { name: 'cli
CKEDITOR.replace ('description');
模板的css代码与网页的代码合并,然后网页采用我从模板中读取的样式并打破样式
我应该做的是,编辑只接受css,而不是网页
我的配置是:
CKEDITOR.editorConfig = function( config ) {
config.toolbarGroups = [
{ name: 'clipboard', groups: [ 'clipboard', 'undo' ] },
{ name: 'editing', groups: [ 'find', 'selection', 'spellchecker' ] },
{ name: 'links' },
{ name: 'insert' },
{ name: 'forms' },
{ name: 'tools' },
{ name: 'document', groups: [ 'mode', 'document', 'doctools' ] },
{ name: 'others' },
{ name: 'basicstyles', groups: [ 'basicstyles', 'cleanup' ] },
{ name: 'paragraph', groups: [ 'list', 'indent', 'blocks', 'align', 'bidi' ] },
{ name: 'styles' },
{ name: 'colors' },
{ name: 'about' }
];
config.removeButtons = 'Underline,Subscript,Superscript';
config.format_tags = 'p;h1;h2;h3;pre';
config.removeDialogTabs = 'image:advanced;link:advanced';
};
有人能帮我吗
谢谢请编辑您的问题并显示CKeditor配置。@SaidbakR准备好了,如果可以,请查看此gif:[链接],thanksQuick黑客可能会使用
!重要信息
因此,您的问题是:编辑器中呈现文本的自定义样式可能会覆盖页面的样式@DiegoguerRowhever,结帐可能会对你有所帮助。