Have a look here:

http://www.dynamicdrive.com/dynamicindex16/richtexteditor/index.htm