469,282 Members | 1,732 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,282 developers. It's quick & easy.

Select Function

Hello,

I have seen the select function used on forms fields, and it
usually takes place immediately after a setfocus call is made.
However, after adding the code to a test page, I don't see what it
does. Can anyone tell me what exactly it does?

Thanks,
Attila
Jul 20 '05 #1
3 4592
Attila wrote:
Hello,

I have seen the select function used on forms fields, and it
usually takes place immediately after a setfocus call is made.
However, after adding the code to a test page, I don't see what it
does. Can anyone tell me what exactly it does?


IT selects the contents of the field...

Compare Test 2 and Test 5: http://dorward.me.uk/www/ph/test.html

--
David Dorward <http://dorward.me.uk/>
Jul 20 '05 #2
Lee
Attila said:

Hello,

I have seen the select function used on forms fields, and it
usually takes place immediately after a setfocus call is made.
However, after adding the code to a test page, I don't see what it
does. Can anyone tell me what exactly it does?


If the field contains any text, the text is selected. That is,
it appears highlighted, and typing in that field will replace
the current contents. If your test page has empty fields, you
won't see anything, because there is no text to select.

Jul 20 '05 #3
That helps. Thanks for the responses!

Attila
Jul 20 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

5 posts views Thread by callmebill | last post: by
22 posts views Thread by MP | last post: by
reply views Thread by zhoujie | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.