Set mouse focus and move cursor to end of input using jQuery

后端 未结 19 2068
醉话见心
醉话见心 2020-12-04 06:42

This question has been asked in a few different formats but I can\'t get any of the answers to work in my scenario.

I am using jQuery to implement command history wh

19条回答
  •  谎友^
    谎友^ (楼主)
    2020-12-04 07:29

    set the value first. then set the focus. when it focuses, it will use the value that exists at the time of focus, so your value must be set first.

    this logic works for me with an application that populates an with the value of a clicked

提交回复
热议问题