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
Built from https://develop.svn.wordpress.org/trunk@59414


git-svn-id: http://core.svn.wordpress.org/trunk@58800 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Andrew Ozz 2024-11-18 19:33:18 +00:00
parent 2c691c2fbd
commit 6813017f32
3 changed files with 6 additions and 4 deletions

View File

@ -659,8 +659,10 @@ jQuery( function($) {
'li.popular-category > label input[type="checkbox"]', 'li.popular-category > label input[type="checkbox"]',
function() { function() {
var t = $(this), c = t.is(':checked'), id = t.val(); var t = $(this), c = t.is(':checked'), id = t.val();
if ( id && t.parents('#taxonomy-'+taxonomy).length ) if ( id && t.parents('#taxonomy-'+taxonomy).length ) {
$('#in-' + taxonomy + '-' + id + ', #in-popular-' + taxonomy + '-' + id).prop( 'checked', c ); $('input[id^="in-' + taxonomy + '-' + id + '"]').prop('checked', c);
$('input#in-popular-' + taxonomy + '-' + id).prop('checked', c);
}
} }
); );

File diff suppressed because one or more lines are too long

View File

@ -16,7 +16,7 @@
* *
* @global string $wp_version * @global string $wp_version
*/ */
$wp_version = '6.8-alpha-59413'; $wp_version = '6.8-alpha-59414';
/** /**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.