Results 1 to 2 of 2
Aug 22, 2007, 06:09 #1
Insert Text into <textarea> on Client
I'm working on a page where I have a <textarea> control and several hyperlinks. I want to be able to enter text into the <textarea> simply by typing, but I also want to be able to insert text into the textarea by clicking on the hyperlinks (The tokens which will be inserted into the textarea by clicking on the hyperlinks will be replaced by dynamic data when the data in the textarea is processed by the server).
<textarea></textarea> <a href="#">[Token1]</a> <a href="#">[Token2]</a> <a href="#">[Token3]</a>
What I want is to insert the text inside the <a> tags into the textarea at the last place the cursor was located. Is this possible?