WYSIWYG text to markup converter

Hey guys! I need your help once again.

I’m creating this simple WYSIWYG rich text editor where users can type in any content and decorate those text (bold, underline, italic). I have a button that would convert take the innerHTML of the iframe and then display that onto a separate div. This may sound strange, but I also want to display the html elements onto the next screen. I tried converting it to text before displaying but it doesn’t work.

any thoughts?

thanks!
Kevin