Adding word to existing text in a textarea

javascript United States
  • 18 years ago

    hmm, anyone here?


    I have written a function to add a word to existing text in a text area, which I call using a button. The problem is that the word is always added at the end of the text. Is it possible to locate the cursor position in a text area? I would like the user to be able to add new words inbetween two exisiting words.


    Doesn anyone know how to track the cursor position in a text area?

  • 18 years ago

    Try this link:


    Forum Link


    We've talked about this before a couple of months ago.


    Hope this helps!




Post a reply

Enter your message below

Sign in or Join us (it's free).

Contribute

Why not write for us? Or you could submit an event or a user group in your area. Alternatively just tell us what you think!

Our tools

We've got automatic conversion tools to convert C# to VB.NET, VB.NET to C#. Also you can compress javascript and compress css and generate sql connection strings.

“Java is to JavaScript what Car is to Carpet.” - Chris Heilmann