QUESTION: Insert tags around highlighted text


#1

Yello,

I have a textarea where the user can write a paragraph. I want to be
able to let them highlight some of their text and then hit a “URL”
button which will insert “[LINK]” before the highlighted text and
“[/LINK]” after the text.

Does anyone know how to do this?


#2

On Jun 18, 2007, at 2:01 PM, Joe P. wrote:

Yello,

I have a textarea where the user can write a paragraph. I want to be
able to let them highlight some of their text and then hit a “URL”
button which will insert “[LINK]” before the highlighted text and
“[/LINK]” after the text.

Does anyone know how to do this?

http://www.google.com/search?q=tiny+mce

Or use something like RedCloth (textile) to do the markup.

-Rob

Rob B. http://agileconsultingllc.com
removed_email_address@domain.invalid


#3

While it’s going to be a little bit of overkill you can check out our
Textile Editor Helper plugin to learn how to do what you’re asking.
The javascript is pretty simple and straightforward.

http://slateinfo.blogs.wvu.edu/plugins/textile_editor_helper

On 6/18/07, Joe P. removed_email_address@domain.invalid wrote:


Posted via http://www.ruby-forum.com/.

Proud supporter of DC United