||View All MessagesBack to WebFX|
If I use selectionStart and SelectionEnd, it returns the positions of the start and end of the selection. Then how would I go about replacing the text in that range with what I want. Would I have to take the value of the whole textarea and do string manipulation then set the whole value over again?
From: Erik Arvidsson
Sent: March 5, 2004
Subject: Re:Textarea inline insertion in Mozilla
Use selectionStart, selectionEnd and value.
In Midas use W3C ranges.
Does anyone know of a way to insert text inline in Mozilla (1.5+). For example if I have a textarea and I want to insert "Hello World" where the user's cursor is. Is this possible? If not, could there be a work-around using Midas?