#24423 closed enhancement (fixed)
After updating the post, only focus post title field if it's empty
Reported by: | klihelp | Owned by: | nacin |
---|---|---|---|
Milestone: | 3.7 | Priority: | normal |
Severity: | normal | Version: | 2.5 |
Component: | Administration | Keywords: | has-patch 3.7-early |
Focuses: | ui | Cc: |
Description
The post formats looks very nice.
One small thing could be more user friendly.
Currently when you change between the post formats then the Title field becomes focused and the title text will be selected.
Happened a lot with me that when I wanted to just use Space to scroll down the page, accidentally deleted the title text. Pressing any key is deleting the selected text in the title field.
Happened a lot with me that when I wanted to just use Space to scroll down the page, but accidentally deleted the title text.
It would be better if the title field getting the focus only if it's empty.
I commented my feedback for Post Format UI title input box, but didn't got any response for that, so I though I open this new ticket.
Attachments (2)
Change History (19)
#1
@
11 years ago
- Summary changed from Blur post title field when title isn't empty to Focus on post title field when title is empty
#4
@
11 years ago
Hi @john, did you closed the correct ticket?
This behaviour is there on the edit post/page ..
When you update the post, the title field get the focus, which gets deleted pressing any key ... except the tab. The most used key is the spacebar and this just deletes the title.
Should be this normal?
#5
@
11 years ago
- Component changed from Post Formats to Administration
Ah now that is interesting. The title field gets focused when you update the post, but not when you first arrive on the edit screen for the post.
I agree, the title field shouldn't be focused when it's not empty. This is not a Post Formats issue, but a general issue.
#8
@
11 years ago
- Milestone changed from Awaiting Review to Future Release
- Version changed from trunk to 2.5
Not a regression, happens all the way back to 2.5.
#9
@
11 years ago
- Summary changed from Focus on post title field when title is empty to After updating the post, only focus post title field if it's empty
#10
@
11 years ago
I added a patch for this. It made sense to take out the PHP if statement altogether and just look at the title field, so we always, and only, focus when the field is blank.
#15
@
11 years ago
I suspect that [1236/trunk/wp-admin/edit-form-advanced.php] was supposed to be if ( ! isset( $_GET['message'] ) || 2 > $_GET['message'] )
. That way if message was not set at all, the title field gets the focus. That logic issue way back when resulted in [6059], which otherwise wasn't needed for new posts.
The way the code is written is it also receives the focus for any message less than 2. That's because in [1197], messages 2 and 3 were added, and they had to do with custom fields, not saving the post. It no longer makes sense.
Yes, it should go.
Looks like the latest patches on #24011 resolve this for Status and Aside formats: ticket:24011:45.