Make WordPress Core

Opened 6 months ago

Closed 6 months ago

#62618 closed defect (bug) (duplicate)

One taxonomy term selected, multiple terms applied

Reported by: aljuk's profile aljuk Owned by:
Milestone: Priority: normal
Severity: major Version: 6.7.1
Component: Editor Keywords:
Focuses: Cc:

Description

I have a client site with a custom taxonomy that has quite a few terms (130). Selecting some terms is suddenly problematic.

When my client creates a new post and selects a particular term to apply in the post editor, two other terms are automagically being selected without her interaction. She selects (checks) one term to apply in the post editor, and ends up with three.

Upon investigation, all three terms have IDs that begin with the same two digits.

The term she selects has ID 67. The other terms that are being automagically added are terms with IDs 673 and 678. There are no other terms in the list whose IDs begin with 67, just these three. I’ve tested myself, and if term with ID 673 or term with 678 is selected, no problem, only that single term is checked. Check 67, however, and all 3 become checked.

I can’t find a logical solution. I think it may be a bug in WP. I’m just awaiting a client response, but I believe this has started happening with the most recent WP update.

Change History (6)

#1 @aljuk
6 months ago

I've rolled back to WP 6.6.2 and the problem has gone away ...

#2 follow-up: @akshat2802
6 months ago

Hii @aljuk
I have tried to replicate the issue with term IDs 4 and 41 on WordPress version 6.7.1.
But for me, it is working fine. If possible can you please attach a screen recording of the issue you were facing for ver 6.7.1 for more clarity.

Regards

#3 in reply to: ↑ 2 @elisavet2ww
6 months ago

Replying to akshat2802:

Hii @aljuk
I have tried to replicate the issue with term IDs 4 and 41 on WordPress version 6.7.1.
But for me, it is working fine. If possible can you please attach a screen recording of the issue you were facing for ver 6.7.1 for more clarity.

Regards

It's happening for the categories that have the popular-categry class

#4 @elisavet2ww
6 months ago

The problem is from post.min.js

h("#" + a + "checklist, #" + a + "checklist-pop").on("click", 'li.popular-category > label input[type="checkbox"]', function() {
            var t = h(this)
              , e = t.is(":checked")
              , i = t.val();
            i && t.parents("#taxonomy-" + a).length && (h('input[id^="in-' + a + "-" + i + '"]').prop("checked", e),
            h("input#in-popular-" + a + "-" + i).prop("checked", e))
        })

#5 @sabernhardt
6 months ago

  • Component changed from Taxonomy to Editor
  • Milestone Awaiting Review deleted

Hi and thanks for the report!

The issue with category selection in the (classic) post editor is already tracked on #62504.

#6 @sabernhardt
6 months ago

  • Resolution set to duplicate
  • Status changed from new to closed

Duplicate of #62504.

Note: See TracTickets for help on using tickets.