[ Index ] |
PHP Cross Reference of WordPress Trunk (Updated Daily) |
[Source view] [Print] [Project Stats]
Locale API: WP_Locale class
File Size: | 459 lines (17 kb) |
Included or required: | 1 time |
Referenced: | 0 times |
Includes or requires: | 0 files |
WP_Locale:: (14 methods):
__construct()
init()
get_weekday()
get_weekday_initial()
get_weekday_abbrev()
get_month()
get_month_abbrev()
get_month_genitive()
get_meridiem()
register_globals()
is_rtl()
_strings_for_pot()
get_list_item_separator()
get_word_count_type()
__construct() X-Ref |
Constructor which calls helper methods to set up object variables. |
init() X-Ref |
Sets up the translated strings and object properties. The method creates the translatable strings for various calendar elements. Which allows for specifying locale specific calendar names and text direction. |
get_weekday( $weekday_number ) X-Ref |
Retrieves the full translated weekday word. Week starts on translated Sunday and can be fetched by using 0 (zero). So the week starts with 0 (zero) and ends on Saturday with is fetched by using 6 (six). return: string Full translated weekday. param: int $weekday_number 0 for Sunday through 6 Saturday. |
get_weekday_initial( $weekday_name ) X-Ref |
Retrieves the translated weekday initial. The weekday initial is retrieved by the translated full weekday word. When translating the weekday initial pay attention to make sure that the starting letter does not conflict. return: string Translated weekday initial. param: string $weekday_name Full translated weekday word. |
get_weekday_abbrev( $weekday_name ) X-Ref |
Retrieves the translated weekday abbreviation. The weekday abbreviation is retrieved by the translated full weekday word. return: string Translated weekday abbreviation. param: string $weekday_name Full translated weekday word. |
get_month( $month_number ) X-Ref |
Retrieves the full translated month by month number. The $month_number parameter has to be a string because it must have the '0' in front of any number that is less than 10. Starts from '01' and ends at '12'. You can use an integer instead and it will add the '0' before the numbers less than 10 for you. return: string Translated full month name. param: string|int $month_number '01' through '12'. |
get_month_abbrev( $month_name ) X-Ref |
Retrieves translated version of month abbreviation string. The $month_name parameter is expected to be the translated or translatable version of the month. return: string Translated abbreviated month. param: string $month_name Translated month to get abbreviated version. |
get_month_genitive( $month_number ) X-Ref |
Retrieves translated version of month genitive string. The $month_number parameter has to be a string because it must have the '0' in front of any number that is less than 10. Starts from '01' and ends at '12'. You can use an integer instead and it will add the '0' before the numbers less than 10 for you. return: string Translated genitive month name. param: string|int $month_number '01' through '12'. |
get_meridiem( $meridiem ) X-Ref |
Retrieves translated version of meridiem string. The $meridiem parameter is expected to not be translated. return: string Translated version param: string $meridiem Either 'am', 'pm', 'AM', or 'PM'. Not translated version. |
register_globals() X-Ref |
Global variables are deprecated. For backward compatibility only. |
is_rtl() X-Ref |
Checks if current locale is RTL. return: bool Whether locale is RTL. |
_strings_for_pot() X-Ref |
Registers date/time format strings for general POT. Private, unused method to add some date/time formats translated on wp-admin/options-general.php to the general POT that would otherwise be added to the admin POT. |
get_list_item_separator() X-Ref |
Retrieves the localized list item separator. return: string Localized list item separator. |
get_word_count_type() X-Ref |
Retrieves the localized word count type. return: string Localized word count type. Possible values are `characters_excluding_spaces`, |
Generated : Sat Dec 21 08:20:01 2024 | Cross-referenced by PHPXref |