Changeset 30542 for trunk/src/wp-includes/l10n.php
- Timestamp:
- 11/24/2014 05:46:04 AM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/l10n.php
r30495 r30542 77 77 * If there is no translation, or the text domain isn't loaded, the original text is returned. 78 78 * 79 * <strong>Note:</strong> Don't use translate() directly, use __()or related functions.79 * *Note:* Don't use {@see translate()} directly, use `{@see __()} or related functions. 80 80 * 81 81 * @since 2.2.0 … … 88 88 $translations = get_translations_for_domain( $domain ); 89 89 $translations = $translations->translate( $text ); 90 90 91 /** 91 92 * Filter text with its translation. … … 365 366 * 366 367 * Example: 367 * <code> 368 * $messages = array( 369 * 'post' => _n_noop('%s post', '%s posts'), 370 * 'page' => _n_noop('%s pages', '%s pages') 371 * ); 372 * ... 373 * $message = $messages[$type]; 374 * $usable_text = sprintf( translate_nooped_plural( $message, $count ), $count ); 375 * </code> 368 * 369 * $messages = array( 370 * 'post' => _n_noop( '%s post', '%s posts' ), 371 * 'page' => _n_noop( '%s pages', '%s pages' ), 372 * ); 373 * ... 374 * $message = $messages[ $type ]; 375 * $usable_text = sprintf( translate_nooped_plural( $message, $count ), $count ); 376 376 * 377 377 * @since 2.5.0
Note: See TracChangeset
for help on using the changeset viewer.