Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

highlight the text in a "text" input

Status
Not open for further replies.

bardley

Programmer
May 8, 2001
121
US
In a text input, is it possible not only to focus but to actually select (highlight, a la cut/paste) the contents of the box?
I tried focus, but it only puts the cursor at the beginning. Brad Gunsalus
Cymtec Systems, Inc.
bgunsalus@cymtec.com
 
use the .select() instead of a .focus() method to highlight the contents of a text inout field --------------------------------------------------
Goals are dreams with deadlines
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top