Opened 19 years ago
Closed 19 years ago
#4416 closed defect (bug) (duplicate)
Save and Continue Editing with blank title/body gets to bad state
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Milestone: | Priority: | normal | |
| Severity: | normal | Version: | 2.2 |
| Component: | Administration | Keywords: | save, post, has-patch |
| Focuses: | Cc: |
Description
Log into your WordPress admin panel.
Click "Write" to create a new post. It does not matter if you are using the rich text editor or plain editor.
Click "Save and Continue Editing", without entering a title or body for your post. (For instance, someone might check a category or enter some other metadata and click Save and Continue Editing; but to reproduce this bug, you can just immediately click Save and Continue Editing)
You will be redirected to a page with the following URL, relative to your blog dir:
wp-admin/post.php?action=edit&post=0
You will see a blank post editing screen, except that any edits you might have made in post metadata, categories, etc., and your usual post defaults (comment/trackback preferences), are all lost.
I think the correct behavior should be (assuming we don't want to save a post with no title/content) to open up the default post again (as if user just clicked on Write), and to warn the user that the post was empty and not saved, up at the top of the screen in one of those handy-dandy fading message bars.
I originally found this bug on a site running 2.1.x. I then verified it is still there in 2.2, and also in [5655], on a fresh install from scratch with no plugins running.
Patches to wp-admin/post.php and wp-admin/post-new.php, which make it so Save and Continue Editing on a blank post goes to new Write screen with warning message at top of screen