views:

841

answers:

2

I implemented the Yahoo Rich Text Editor (YUI Editor) in a Rails application using the YUI_Editor Plugin.

If I copy/paste text out of a PDF into a YUI-Editor-enhanced-TextArea (YEETA :)) it does not only copy the text but also the formatting of it.

How do I configure the YUI Editor to remove all formatting of text pasted into the YEETA before inserting it?

I'm intrested in your answer even if you're not working with Rails and/or using the YUI_Editor plugin. Give me a hint and I'll figure out how to solve this with my setup.

Thanks a lot for your help!

A: 

As far as I know there is no such function in the YUI editor. Finally I parsed the editor content on submit as described on this question.

Javier
+1  A: 

I've written an extension to the YUI editor to handle this, you can download it here:

http://antscode.blogspot.com/2009/05/strip-formatting-on-paste-using-yui.html

antscode
thanks a lot (though I switched to TinyMCE in the meantime ;-))!
Javier