You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Shane Petroff <sh...@mayet.ca> on 2008/04/23 18:09:56 UTC
[Trinidad] Caret position
Hello,
How can I get the current caret position from a tr:inputText component
over to some server side code? I have an action which is used to open a
dialog, and at that point I want to grab the current caret position for
use in the dialog's return listener. Googling 'java Trinidad "caret
position"' turns up virtually nothing, and searching for the erroneous
label 'cursor' naturally turns up boatloads of pages related to the
proper use of the word.
--
Shane
Re: [Trinidad] Caret position
Posted by Andrew Robinson <an...@gmail.com>.
One idea:
Look up the input text via document.getElementById(), then use JS to
get the caret position, set the value in an inputHidden and use that
control to decode the location and store it somewhere you have access
to.
On Wed, Apr 23, 2008 at 10:09 AM, Shane Petroff <sh...@mayet.ca> wrote:
> Hello,
>
> How can I get the current caret position from a tr:inputText component over
> to some server side code? I have an action which is used to open a dialog,
> and at that point I want to grab the current caret position for use in the
> dialog's return listener. Googling 'java Trinidad "caret position"' turns up
> virtually nothing, and searching for the erroneous label 'cursor' naturally
> turns up boatloads of pages related to the proper use of the word.
>
> --
> Shane
>
>