weekday[0] = __('Pazar'); $this->weekday[1] = __('Pazartesi'); $this->weekday[2] = __('Salı'); $this->weekday[3] = __('Çarşamba'); $this->weekday[4] = __('Perşembe'); $this->weekday[5] = __('Cuma'); $this->weekday[6] = __('Cumartesi'); // The first letter of each day. The _%day%_initial suffix is a hack to make // sure the day initials are unique. $this->weekday_initial[__('Pazar')] = __('P_Pazar_initial'); $this->weekday_initial[__('Pazartesi')] = __('P_Pazartesi_initial'); $this->weekday_initial[__('Salı')] = __('S_Salı_initial'); $this->weekday_initial[__('Çarşamba')] = __('Ç_Çarşamba_initial'); $this->weekday_initial[__('Perşembe')] = __('P_Perşembe_initial'); $this->weekday_initial[__('Cuma')] = __('C_Cuma_initial'); $this->weekday_initial[__('Cumartesi')] = __('C_Cumartesi_initial'); foreach ($this->weekday_initial as $weekday_ => $weekday_initial_) { $this->weekday_initial[$weekday_] = preg_replace('/_.+_initial$/', '', $weekday_initial_); } // Abbreviations for each day. $this->weekday_abbrev[__('Pazar')] = __('Paz'); $this->weekday_abbrev[__('Pazartesi')] = __('Pzt'); $this->weekday_abbrev[__('Salı')] = __('Sal'); $this->weekday_abbrev[__('Çarşamba')] = __('Çar'); $this->weekday_abbrev[__('Perşembe')] = __('Per'); $this->weekday_abbrev[__('Cuma')] = __('Cum'); $this->weekday_abbrev[__('Cumartesi')] = __('Cmt'); // The Months $this->month['01'] = __('Ocak'); $this->month['02'] = __('Şubat'); $this->month['03'] = __('Mart'); $this->month['04'] = __('Nisan'); $this->month['05'] = __('Mayıs'); $this->month['06'] = __('Haziran'); $this->month['07'] = __('Temmuz'); $this->month['08'] = __('Ağustos'); $this->month['09'] = __('Eylül'); $this->month['10'] = __('Ekim'); $this->month['11'] = __('Kasım'); $this->month['12'] = __('Aralık'); // Abbreviations for each month. Uses the same hack as above to get around the // 'Mayıs' duplication. $this->month_abbrev[__('Ocak')] = __('Oca_Ocak_abbreviation'); $this->month_abbrev[__('Şubat')] = __('Şub_Şubat_abbreviation'); $this->month_abbrev[__('Mart')] = __('Mar_Mart_abbreviation'); $this->month_abbrev[__('Nisan')] = __('Nis_Nisan_abbreviation'); $this->month_abbrev[__('Mayıs')] = __('May_Mayıs_abbreviation'); $this->month_abbrev[__('Haziran')] = __('Haz_Haziran_abbreviation'); $this->month_abbrev[__('Temmuz')] = __('Tem_Temmuz_abbreviation'); $this->month_abbrev[__('Ağustos')] = __('Ağu_Ağustos_abbreviation'); $this->month_abbrev[__('Eylül')] = __('Eyl_Eylül_abbreviation'); $this->month_abbrev[__('Ekim')] = __('Eki_Ekim_abbreviation'); $this->month_abbrev[__('Kasım')] = __('Kas_Kasım_abbreviation'); $this->month_abbrev[__('Aralık')] = __('Ara_Aralık_abbreviation'); foreach ($this->month_abbrev as $month_ => $month_abbrev_) { $this->month_abbrev[$month_] = preg_replace('/_.+_abbreviation$/', '', $month_abbrev_); } // The Meridiems $this->meridiem['am'] = __('am'); $this->meridiem['pm'] = __('pm'); $this->meridiem['AM'] = __('AM'); $this->meridiem['PM'] = __('PM'); // Numbers formatting // See http://php.net/number_format /* translators: $decimals argument for http://php.net/number_format, default is 0 */ $trans = __('number_format_decimals'); $this->number_format['decimals'] = ('number_format_decimals' == $trans) ? 0 : $trans; /* translators: $dec_point argument for http://php.net/number_format, default is . */ $trans = __('number_format_decimal_point'); $this->number_format['decimal_point'] = ('number_format_decimal_point' == $trans) ? '.' : $trans; /* translators: $thousands_sep argument for http://php.net/number_format, default is , */ $trans = __('number_format_thousands_sep'); $this->number_format['thousands_sep'] = ('number_format_thousands_sep' == $trans) ? ',' : $trans; // Import global locale vars set during inclusion of $locale.php. foreach ( (array) $this->locale_vars as $var ) { if ( isset($GLOBALS[$var]) ) $this->$var = $GLOBALS[$var]; } } /** * Retrieve the full translated weekday word. * * Week starts on translated Pazar and can be fetched * by using 0 (zero). So the week starts with 0 (zero) * and ends on Cumartesi with is fetched by using 6 (six). * * @since 2.1.0 * @access public * * @param int $weekday_number 0 for Pazar through 6 Cumartesi * @return string Full translated weekday */ function get_weekday($weekday_number) { return $this->weekday[$weekday_number]; } /** * Retrieve 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. * * @since 2.1.0 * @access public * * @param string $weekday_name * @return string */ function get_weekday_initial($weekday_name) { return $this->weekday_initial[$weekday_name]; } /** * Retrieve the translated weekday abbreviation. * * The weekday abbreviation is retrieved by the translated * full weekday word. * * @since 2.1.0 * @access public * * @param string $weekday_name Full translated weekday word * @return string Translated weekday abbreviation */ function get_weekday_abbrev($weekday_name) { return $this->weekday_abbrev[$weekday_name]; } /** * Retrieve 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. * * @since 2.1.0 * @access public * * @param string|int $month_number '01' through '12' * @return string Translated full month name */ function get_month($month_number) { return $this->month[zeroise($month_number, 2)]; } /** * Retrieve translated version of month abbreviation string. * * The $month_name parameter is expected to be the translated or * translatable version of the month. * * @since 2.1.0 * @access public * * @param string $month_name Translated month to get abbreviated version * @return string Translated abbreviated month */ function get_month_abbrev($month_name) { return $this->month_abbrev[$month_name]; } /** * Retrieve translated version of meridiem string. * * The $meridiem parameter is expected to not be translated. * * @since 2.1.0 * @access public * * @param string $meridiem Either 'am', 'pm', 'AM', or 'PM'. Not translated version. * @return string Translated version */ function get_meridiem($meridiem) { return $this->meridiem[$meridiem]; } /** * Global variables are deprecated. For backwards compatibility only. * * @deprecated For backwards compatibility only. * @access private * * @since 2.1.0 */ function register_globals() { $GLOBALS['weekday'] = $this->weekday; $GLOBALS['weekday_initial'] = $this->weekday_initial; $GLOBALS['weekday_abbrev'] = $this->weekday_abbrev; $GLOBALS['month'] = $this->month; $GLOBALS['month_abbrev'] = $this->month_abbrev; } /** * PHP4 style constructor which calls helper methods to set up object variables * * @uses WP_Locale::init() * @uses WP_Locale::register_globals() * @since 2.1.0 * * @return WP_Locale */ function WP_Locale() { $this->init(); $this->register_globals(); } } ?>