關於ckeditor添加的class都會被清除掉的問題

在源碼中輸入ul,而且帶有class,而後點擊源碼,到可視化界面html

結果顯示爲aaa,再點看源碼,查看HTML源代碼code

 

解決方法:htm

添加配置 config.allowedContent = true

這個配置是關閉過濾內容的設置。
也能夠經過
config.extraAllowedContent = 'div(*)';來擴展過濾屬性和標籤參考資料:http://stackoverflow.com/questions/15659390/ckeditor-automatically-strips-classes-from-div          http://www.szfangwei.cn/news/2309.html          http://xieyanxy9.iteye.com/blog/2032972          http://q.cnblogs.com/q/52291/          http://www.thinksaas.cn/group/topic/345153/
相關文章
相關標籤/搜索