By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
437,648 Members | 1,190 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 437,648 IT Pros & Developers. It's quick & easy.

textarea problems

P: n/a
say i have a form where, if a user clicks in it, all the text is
highlighted, and where, if a user clicks on a button outside of the
form, a certain text string is inserted where the cursor in the
textarea is. why is it, then, that when i, immediatly after loading
the page, click in the textarea, highlighting the text, click again in
the middle of the text (effectively unhighlighting everything, as
well), and then click on the button to insert to the text, the text
string that is to be inserted appears outside of the form?

here's a working demonstration:

http://www.geocities.com/terra1024/error-forms.html

if you click right before the first and only capatilized T twice, and
then click on the ### link underneath the text area, ### is not
inserted into the form, as i would like, but is rather inserted
outside of the form.

if i comment out the function that is responsible for the
highlighting, it works just fine, although i can't see, for the life
of me, what in the highlighting function is causing this...

any help would be appreciated - thanks! :)
Jul 20 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
yawnmoth wrote:
say i have a form where, if a user clicks in it, all the text is
highlighted, and where, if a user clicks on a button outside of the
form, a certain text string is inserted where the cursor in the
textarea is.
This sounds like javascript, and thus off topic for this group.
here's a working demonstration:

http://www.geocities.com/terra1024/error-forms.html
As I guessed, this is a javascript question.
any help would be appreciated


Ask in a javascript group (after checking their faq, etc.).

--
Brian (remove ".invalid" to email me)
http://www.tsmchughs.com/
Jul 20 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.