Add number_format_i18n filter. Props kambiz.k. fixes #7753

git-svn-id: http://svn.automattic.com/wordpress/trunk@11407 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan 2009-05-20 16:08:35 +00:00
parent 458a0cf306
commit 681f0ba58c
1 changed files with 4 additions and 1 deletions

View File

@ -140,7 +140,10 @@ function number_format_i18n( $number, $decimals = null ) {
// let the user override the precision only // let the user override the precision only
$decimals = ( is_null( $decimals ) ) ? $wp_locale->number_format['decimals'] : intval( $decimals ); $decimals = ( is_null( $decimals ) ) ? $wp_locale->number_format['decimals'] : intval( $decimals );
return number_format( $number, $decimals, $wp_locale->number_format['decimal_point'], $wp_locale->number_format['thousands_sep'] ); $num = number_format( $number, $decimals, $wp_locale->number_format['decimal_point'], $wp_locale->number_format['thousands_sep'] );
// let the user translate digits from latin to localized language
return apply_filters( 'number_format_i18n', $num );
} }
/** /**