_n_noop
Registers plural strings 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:
Returns (array)
{ Array of translation information for the strings. @type string $0 Singular form to be localized. No longer used. @type string $1 Plural form to be localized. No longer used. @type string $singular Singular form to be localized. @type string $plural Plural form to be localized. @type null $context Context information for the translators. @type string $domain Text domain. }
Parameters (3)
- 0. $singular (string)
- Singular form to be localized.
- 1. $plural (string)
- Plural form to be localized.
- 2. $domain — Optional. (null) =>
null
- Text domain. Unique identifier for retrieving translated strings. Default null.
Usage
if ( !function_exists( '_n_noop' ) ) { require_once ABSPATH . WPINC . '/l10n.php'; } // Singular form to be localized. $singular = ''; // Plural form to be localized. $plural = ''; // Optional. Text domain. Unique identifier for retrieving translated strings. // Default null. $domain = null; // NOTICE! Understand what this does before running. $result = _n_noop($singular, $plural, $domain);
Defined (1)
The function is defined in the following location(s).
- /wp-includes/l10n.php
- function _n_noop( $singular, $plural, $domain = null ) {
- return array( 0 => $singular, 1 => $plural, 'singular' => $singular, 'plural' => $plural, 'context' => null, 'domain' => $domain );
- }