Registers plural strings with gettext context in POT file, but does not translate them.
Description
Used when you want to keep structures with translatable plural strings and use them later when the number is known. Example of a generic phrase which is disambiguated via the context parameter: $messages = array(
'people' => _nx_noop( '%s group', '%s groups', 'people', 'text-domain' ),
'animals' => _nx_noop( '%s group', '%s groups', 'animals', 'text-domain' ),
);
...
$message = $messages[ $type ];
printf( translate_nooped_plural( $message, $count, 'text-domain' ), number_format_i18n( $count ) );
Parameters
$singularstring
Singular form to be localized.
$pluralstring
Plural form to be localized.
$contextstring
Context information for the translators.
$domainstringoptional
Text domain. Unique identifier for retrieving translated strings. Default null.Default: null
Return
array
Array of translation information for the strings.
$0string
Singular form to be localized. No longer used.
$1string
Plural form to be localized. No longer used.
$2string
Context information for the translators. No longer used.
Signature, return type and hooks compared across 5 parsed releases.
About this page
Parsed data
Generated from the wordpress-develop 6.8.8 tag, from src/wp-includes/l10n.php, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.
Corrections
Something wrong on this page? Report it and it gets fixed in the next regeneration.