I'm wondering how I can insert text into a text area using jquery, upon the click of an anchor tag.
I don't want to replace text already in textarea, I want to append new text to textarea.
I'm wondering how I can insert text into a text area using jquery, upon the click of an anchor tag.
I don't want to replace text already in textarea, I want to append new text to textarea.
It works good for me in Chrome 20.0.11
If you want to append content to the textarea without replacing them, You can try the below
According to your scenario it would be
What you ask for should be reasonably straightforward in jQuery-
The best way that I can think of highlighting inserted text is by wrapping it in a span with a CSS class with
background-color
set to the color of your choice. On the next insert, you could remove the class from any existing spans (or strip the spans out).However, There are plenty of free WYSIWYG HTML/Rich Text editors available on the market, I'm sure one will fit your needs
I used that and it work fine :)
Remi
From what you have in Jason's comments try:
Edit- To append to text look at below