mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 11:28:25 +00:00
Applied patch by 'mark_story' making form helper month names i18n ready, fixes #4409
git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@6950 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
parent
b1ff00d0d3
commit
9e79d1768c
1 changed files with 12 additions and 3 deletions
|
@ -1596,9 +1596,18 @@ class FormHelper extends AppHelper {
|
|||
}
|
||||
break;
|
||||
case 'month':
|
||||
for ($i = 1; $i <= 12; $i++) {
|
||||
$data[sprintf("%02s", $i)] = strftime("%B", mktime(1, 1, 1, $i, 1, 1999));
|
||||
}
|
||||
$data['01'] = __('January', true);
|
||||
$data['02'] = __('February', true);
|
||||
$data['03'] = __('March', true);
|
||||
$data['04'] = __('April', true);
|
||||
$data['05'] = __('May', true);
|
||||
$data['06'] = __('June', true);
|
||||
$data['07'] = __('July', true);
|
||||
$data['08'] = __('August', true);
|
||||
$data['09'] = __('September', true);
|
||||
$data['10'] = __('October', true);
|
||||
$data['11'] = __('November', true);
|
||||
$data['12'] = __('December', true);
|
||||
break;
|
||||
case 'year':
|
||||
$current = intval(date('Y'));
|
||||
|
|
Loading…
Reference in a new issue