Textile advice

Hi all,
I am wander if there what would be the best way to convert HTML to
textile format. What I would like is to allow users to paste content
from clipboard, parse it, dump all that’s not allowed and format in it
textile (something similiar TinyMCE and rich text other editors do when
you paste from word).

I would like to hear if there is any parser or better way to do it.

Thanks for your thoughts.

Bojan M.
Informatika Mihelac, Bojan M. s.p. | www.informatikamihelac.com
→ tools, scripts, tricks from our code lab: http://source.mihelac.org