1

Topic: Add attribute to element in Editor but not in the output (<textarea>)

Is there a way to add attributes to elements in the editor but not have them apply the the textarea? I have tried this code;

tinymce.activeEditor.dom.addClass(tinymce.activeEditor.dom.select('p'), 'myclass');

but that adds the class to the text in the textarea as well, which I don't want.