[wp-trac] [WordPress Trac] #17115: Publishing an empty post results in success

WordPress Trac noreply at wordpress.org
Tue Apr 21 08:48:14 UTC 2015


#17115: Publishing an empty post results in success
------------------------------------+------------------------------
 Reporter:  kawauso                 |       Owner:
     Type:  defect (bug)            |      Status:  new
 Priority:  normal                  |   Milestone:  Awaiting Review
Component:  Posts, Post Types       |     Version:  3.1
 Severity:  normal                  |  Resolution:
 Keywords:  has-patch dev-feedback  |     Focuses:  administration
------------------------------------+------------------------------

Comment (by dnaber-de):

 I don't think that this issue can be solved with JavaScript. Such a
 solution would add only more restrictions to the UI. The filter
 `wp_insert_post_empty_content` explicit allows to override the default
 guard. With an additionally JavaScript inhibitor one would have to
 override two points to make empty posts publishable.

 `wp_insert_post()` by default returns `0` when trying to publish an empty
 post via the Admin-UI, which is correct. The resulting message ID (`/wp-
 admin/post.php?post=4&action=edit&message=6`) is just wrong.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/17115#comment:25>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list