Вопрос

Is there a way I can get the list of tags and attributes for a particular instance of ckeditor which the Advanced Content Filter will allow so that I can pass just those values to santize function in backend and strip away the rest?

We are using ckeditor 4.1 as WYSIWYG editor and rails 3.2 as backend.

Это было полезно?

Решение

You can find all rules in the filter.allowedContent array:

editorInstance.filter.allowedContent

This array contains a unified version of rules so you can assume that they are all in the same format. However, this is not an optimised format, so you may need to process it in order to extract the information which you need.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top