Changeset 20648
- Timestamp:
- 04/30/2012 04:18:35 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/l10n.php
r19772 r20648 273 273 * @param string $singular Single form to be i18ned 274 274 * @param string $plural Plural form to be i18ned 275 * @param string $domain Optional. The domain identifier the text will be retrieved in 275 276 * @return array array($singular, $plural) 276 277 */ 277 function _n_noop( $singular, $plural ) {278 return array( 0 => $singular, 1 => $plural, 'singular' => $singular, 'plural' => $plural, 'context' => null );278 function _n_noop( $singular, $plural, $domain = null ) { 279 return array( 0 => $singular, 1 => $plural, 'singular' => $singular, 'plural' => $plural, 'context' => null, 'domain' => $domain ); 279 280 } 280 281 … … 284 285 * @see _n_noop() 285 286 */ 286 function _nx_noop( $singular, $plural, $context ) {287 return array( 0 => $singular, 1 => $plural, 2 => $context, 'singular' => $singular, 'plural' => $plural, 'context' => $context );287 function _nx_noop( $singular, $plural, $context, $domain = null ) { 288 return array( 0 => $singular, 1 => $plural, 2 => $context, 'singular' => $singular, 'plural' => $plural, 'context' => $context, 'domain' => $domain ); 288 289 } 289 290 … … 294 295 * @param array $nooped_plural Array with singular, plural and context keys, usually the result of _n_noop() or _nx_noop() 295 296 * @param int $count Number of objects 296 * @param string $domain Optional. The domain identifier the text should be retrieved in 297 * @param string $domain Optional. The domain identifier the text should be retrieved in. If $nooped_plural contains 298 * a domain passed to _n_noop() or _nx_noop(), it will override this value. 297 299 */ 298 300 function translate_nooped_plural( $nooped_plural, $count, $domain = 'default' ) { 301 if ( $nooped_plural['domain'] ) 302 $domain = $nooped_plural['domain']; 303 299 304 if ( $nooped_plural['context'] ) 300 305 return _nx( $nooped_plural['singular'], $nooped_plural['plural'], $count, $nooped_plural['context'], $domain );
Note: See TracChangeset
for help on using the changeset viewer.