douzhan8303 2017-06-20 08:51
浏览 213

ckeditor 4.7.0删除样式属性

i read more article about how to allow ckeditor to accept all attribute and how to fix it, but still i have problem. ckeditor remove style attribute. i try to justify text or change color ,....;

here is what i do:

ckeditor/config.js

/**
 * @license Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
 * For licensing, see LICENSE.md or http://ckeditor.com/license
 */

CKEDITOR.editorConfig = function( config ) {
    config.allowedContent = true;
    config.extraAllowedContent = 'style;*[id,rel](*){*}';//
    config.removeFormatAttributes = '';
};

but when i insert data into database i see:

<p [removed] center;">

i read [CKEditor strips inline attributes

[1]: CKEditor strips inline attributes and to more option like config.extraAllowedContent = '*{*}'; but still no luck.

any suggestion ?

  • 写回答

0条回答 默认 最新

    报告相同问题?

    悬赏问题

    • ¥40 复杂的限制性的商函数处理
    • ¥15 程序不包含适用于入口点的静态Main方法
    • ¥15 素材场景中光线烘焙后灯光失效
    • ¥15 请教一下各位,为什么我这个没有实现模拟点击
    • ¥15 执行 virtuoso 命令后,界面没有,cadence 启动不起来
    • ¥50 comfyui下连接animatediff节点生成视频质量非常差的原因
    • ¥20 有关区间dp的问题求解
    • ¥15 多电路系统共用电源的串扰问题
    • ¥15 slam rangenet++配置
    • ¥15 有没有研究水声通信方面的帮我改俩matlab代码