Look at tinyMCE as an editor, it's open source and free.
As for the archiving bit, if I used a website page as an example:
Have a table with all your website pages in it then have another table with the content in it. The table with the content in it stores the page id, the content and a...