Make WordPress Core

Changeset 59414


Ignore:
Timestamp:
11/18/2024 07:31:45 PM (2 years ago)
Author:
azaozz
Message:

Editor: Fix the JS to select, save, and update categories on the old Edit Post screen.

Props: charleslf, im3dabasia1, desrosj, dhruvang21, Zargarov, sainathpoojary, azaozz
Fixes: #62440

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/js/_enqueues/admin/post.js

    r59188 r59414  
    660660                        function() {
    661661                                var t = $(this), c = t.is(':checked'), id = t.val();
    662                                 if ( id && t.parents('#taxonomy-'+taxonomy).length )
    663                                         $('#in-' + taxonomy + '-' + id + ', #in-popular-' + taxonomy + '-' + id).prop( 'checked', c );
     662                                if ( id && t.parents('#taxonomy-'+taxonomy).length ) {
     663                                        $('input[id^="in-' + taxonomy + '-' + id + '"]').prop('checked', c);
     664                                        $('input#in-popular-' + taxonomy + '-' + id).prop('checked', c);
     665                                }
    664666                        }
    665667                );
Note: See TracChangeset for help on using the changeset viewer.