WordPress.org

Make WordPress Core

Opened 3 years ago

Closed 10 months ago

Last modified 10 months ago

#40681 closed defect (bug) (duplicate)

The "Edit Post" page appears to MOVE a category to the top based on bad logic, instead of leaving it under its parent.

Reported by: DScotese Owned by:
Milestone: Priority: normal
Severity: normal Version: 4.7.4
Component: Editor Keywords:
Focuses: ui, template Cc:

Description

I recommend updating this page so that you have a more concise list of these questions, just to cut down on the size of the descriptions we submit to you (from those who simply copy/paste them, like me):

Are you using either the latest version of WordPress, or the latest development version? If not, please update first.

I understand that our installation keeps itself up to date.

What steps should be taken to consistently reproduce the problem?

  1. Create a Top level category.
  2. Create a category under it.
  3. Create a new post in the child.
  4. Observe that after saving the new post, the child category is displayed at the top of the category list.

Does the problem occur even when you deactivate all plugins and use the default theme?

We don't have a test version of the site yet, and we don't want to disturb visitors on the site, so we have not yet tested this with any of the following disabled:
Disqus Comment System; MailChimp for WordPress; Recent Posts Widget Extended; Swifty Image Widget by WPGens; Yoast SEO

In case it's relevant to the ticket, what is the expected output or result? What did you see instead?

Good point. I expected the list to leave the category in the list under the parent category. It does seem smart to move it to the top, but if you do that, I suggest that since it's a child category, it still be indented - at least once - maybe with a circled question-mark tooltip explaining that the indentation only means "This category has a parent category that can be found below."

Change History (2)

#1 @pento
10 months ago

  • Milestone Awaiting Review deleted
  • Resolution set to fixed
  • Status changed from new to closed

While this behaviour still exists in the classic editor, it has been fixed in the block editor, so I'm going to close this ticket.

#2 @SergeyBiryukov
10 months ago

  • Resolution changed from fixed to duplicate

Hi there, welcome to WordPress Trac!

Thanks for the ticket, sorry it took so long for someone to get back to you.

Per the discussion in #10982, this is intentional behavior for the classic editor. A filter was added in #20054, allowing plugins to change it. This plugin implements the change: https://wordpress.org/plugins/category-checklist-tree/.

As noted above, this is fixed in the block editor introduced with WordPress 5.0.

Note: See TracTickets for help on using tickets.