(Requires: 3.0)
This option enables you specify a function that all classes will be passed through when the auto import classes feature is used with TinyMCE.
Example of usage of the class_filter option:
tinyMCE.init({
...
class_filter : function(cls, rule) {
// Block the someClass
if (cls == 'someClass')
return false;
// Swap the otherClass
if (cls == 'otherClass')
return 'someOtherClass';
// Skip classes that are inside id like #id .myclass
if (/^#.*/.test(rule))
return false;
// Pass though the rest
return cls;
}
});
Was this article helpful? Yes - No
Well, that's awkward . Would you mind opening an issue or helping us out?
Thanks for the feedback!
Except as otherwise noted, the content of this page is licensed under the Creative Commons BY-NC-SA 3.0 License, and code samples are licensed under the Apache 2.0 License.