Rich Text to Simple Text

Thanks, Patrick! It worked beautifully!
I added a code below to get rid of line breaks.

.replace(/\r?\n/g,"")