[wp-trac] [WordPress Trac] #21656: Focusing on code textareas during setup should select all

WordPress Trac wp-trac at lists.automattic.com
Sun Sep 16 18:26:35 UTC 2012


#21656: Focusing on code textareas during setup should select all
-------------------------------------+------------------
 Reporter:  jblz                     |       Owner:
     Type:  enhancement              |      Status:  new
 Priority:  normal                   |   Milestone:  3.5
Component:  Upgrade/Install          |     Version:
 Severity:  normal                   |  Resolution:
 Keywords:  has-patch needs-testing  |
-------------------------------------+------------------

Comment (by nacin):

 Automatically selecting on focus/enter/click can be confusing to users,
 and also buggy — certain keyboard or mouse events might act in strange
 ways, which pose problems for both accessibility and for keystrokes done
 by power users. I broke this a few times, though I may have been doing it
 wrong.

 On network.php, we deliberately show all lines, with no scroll. I do want
 to adjust setup-config.php, as with scrollbars often being hidden in newer
 browsers and operating systems, it's definitely possible to only grab the
 visible portion.

 I came up with calling .focus() and .select() on the textarea, and it
 worked well for me. What do you think?

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/21656#comment:2>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list