xref: /webtrees/resources/views/edit/initialize-calendar-popup.phtml (revision d62ae68e24d451faa2c02451650eabf25a43a980)
1<?php
2
3use Fisharebest\Webtrees\I18N;
4
5?>
6<?php use Fisharebest\Webtrees\View; ?>
7
8<?php View::push('javascript') ?>
9<script>
10  cal_setMonthNames(
11        <?= json_encode(I18N::translateContext('NOMINATIVE', 'January')) ?>,
12        <?= json_encode(I18N::translateContext('NOMINATIVE', 'February')) ?>,
13        <?= json_encode(I18N::translateContext('NOMINATIVE', 'March')) ?>,
14        <?= json_encode(I18N::translateContext('NOMINATIVE', 'April')) ?>,
15        <?= json_encode(I18N::translateContext('NOMINATIVE', 'May')) ?>,
16        <?= json_encode(I18N::translateContext('NOMINATIVE', 'June')) ?>,
17        <?= json_encode(I18N::translateContext('NOMINATIVE', 'July')) ?>,
18        <?= json_encode(I18N::translateContext('NOMINATIVE', 'August')) ?>,
19        <?= json_encode(I18N::translateContext('NOMINATIVE', 'September')) ?>,
20        <?= json_encode(I18N::translateContext('NOMINATIVE', 'October')) ?>,
21        <?= json_encode(I18N::translateContext('NOMINATIVE', 'November')) ?>,
22        <?= json_encode(I18N::translateContext('NOMINATIVE', 'December')) ?>
23  );
24
25  cal_setDayHeaders(
26        <?= json_encode(I18N::translate('Sun')) ?>,
27        <?= json_encode(I18N::translate('Mon')) ?>,
28        <?= json_encode(I18N::translate('Tue')) ?>,
29        <?= json_encode(I18N::translate('Wed')) ?>,
30        <?= json_encode(I18N::translate('Thu')) ?>,
31        <?= json_encode(I18N::translate('Fri')) ?>,
32        <?= json_encode(I18N::translate('Sat')) ?>
33  );
34
35  cal_setWeekStart(<?= I18N::locale()->territory()->firstDay() ?>);
36</script>
37<?php View::endpush() ?>
38