From c5856b0a7c2870803f2d4f3b8cbd8fcc940c4156 Mon Sep 17 00:00:00 2001 From: Aki Hamano Date: Tue, 28 Jul 2026 18:08:49 +0900 Subject: [PATCH] Options, Meta APIs: Support plural forms for count labels in Settings. The `posts` and `items` labels on the Reading Settings screen, and the comment spam link count string on the Discussion Settings screen, were single hardcoded strings, forcing translators into whichever plural form they guessed at. Wrap them in `_n_noop()` and resolve them with `translate_nooped_plural()` against the saved option value, and add translator comments. Also replaces `form_option()` with an escaped `get_option()` call for the two number fields, since the values are now needed as integers. Props shailu25, GaryJ, SergeyBiryukov, pavelevap, johnbillion. See #29299. Co-Authored-By: Claude --- src/wp-admin/options-discussion.php | 13 ++++++++++--- src/wp-admin/options-reading.php | 25 +++++++++++++++++++++++-- 2 files changed, 33 insertions(+), 5 deletions(-) diff --git a/src/wp-admin/options-discussion.php b/src/wp-admin/options-discussion.php index f8e4d5040f4e7..daa6aea1676db 100644 --- a/src/wp-admin/options-discussion.php +++ b/src/wp-admin/options-discussion.php @@ -184,10 +184,17 @@

diff --git a/src/wp-admin/options-reading.php b/src/wp-admin/options-reading.php index 31facac7edcca..28d1d8f515390 100644 --- a/src/wp-admin/options-reading.php +++ b/src/wp-admin/options-reading.php @@ -177,12 +177,33 @@ - + + + - + + + +