Auto selecting text?

Discussion in 'JavaScript' started by Xphic, Mar 24, 2008.

  1. #1
    Hey, you know in photobucket how it will automatically select the textbox for users that upload images.

    Well I am try to do that, imgsync has the same thing, Any ideas on how to achieve that?
     
    Xphic, Mar 24, 2008 IP
  2. scubita

    scubita Peon

    Messages:
    5,550
    Likes Received:
    318
    Best Answers:
    0
    Trophy Points:
    0
  3. dnbox

    dnbox Peon

    Messages:
    108
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    0
    #3
    <input name="" type="text" value="auto select text" onclick="javascript:this.select();" readonly="yes" />
    Code (markup):
    :D
     
    dnbox, Mar 24, 2008 IP
  4. Xphic

    Xphic Active Member

    Messages:
    1,323
    Likes Received:
    20
    Best Answers:
    0
    Trophy Points:
    80
    #4
    Alright, thank you, and I googled it to but couldn't find anything, what did you search for?
     
    Xphic, Mar 24, 2008 IP
  5. scubita

    scubita Peon

    Messages:
    5,550
    Likes Received:
    318
    Best Answers:
    0
    Trophy Points:
    0
    #5
    scubita, Mar 24, 2008 IP
  6. QiSoftware

    QiSoftware Well-Known Member

    Messages:
    805
    Likes Received:
    10
    Best Answers:
    0
    Trophy Points:
    158
    #6
    In an onload function call you could also set focus for the input text field if you provide the name identifer.

    Q...
     
    QiSoftware, Mar 24, 2008 IP