diff options
Diffstat (limited to 'app')
47 files changed, 542 insertions, 542 deletions
diff --git a/app/Controller/AdvancedSearchController.php b/app/Controller/AdvancedSearchController.php index 7ba2631ccf..86b8b2e17c 100644 --- a/app/Controller/AdvancedSearchController.php +++ b/app/Controller/AdvancedSearchController.php @@ -133,7 +133,7 @@ class AdvancedSearchController extends SearchController { } $fields = array(); foreach ($ofields as $field) { - $fields[$field] = WT_Gedcom_Tag::GetLabel($field); + $fields[$field] = GedcomTag::GetLabel($field); } uksort($fields, __NAMESPACE__ . '\AdvancedSearchController::tagSort'); return $fields; @@ -150,11 +150,11 @@ class AdvancedSearchController extends SearchController { public static function tagSort($x, $y) { list($x1) = explode(':', $x . ':'); list($y1) = explode(':', $y . ':'); - $tmp = I18N::strcasecmp(WT_Gedcom_Tag::getLabel($x1), WT_Gedcom_Tag::getLabel($y1)); + $tmp = I18N::strcasecmp(GedcomTag::getLabel($x1), GedcomTag::getLabel($y1)); if ($tmp) { return $tmp; } else { - return I18N::strcasecmp(WT_Gedcom_Tag::getLabel($x), WT_Gedcom_Tag::getLabel($y)); + return I18N::strcasecmp(GedcomTag::getLabel($x), GedcomTag::getLabel($y)); } } @@ -200,7 +200,7 @@ class AdvancedSearchController extends SearchController { * @return string */ function getLabel($tag) { - return WT_Gedcom_Tag::getLabel(preg_replace('/:(SDX|BEGINS|EXACT|CONTAINS)$/', '', $tag)); + return GedcomTag::getLabel(preg_replace('/:(SDX|BEGINS|EXACT|CONTAINS)$/', '', $tag)); } /** diff --git a/app/Controller/BranchesController.php b/app/Controller/BranchesController.php index 0fd28ff29e..96c67ee76f 100644 --- a/app/Controller/BranchesController.php +++ b/app/Controller/BranchesController.php @@ -217,7 +217,7 @@ class BranchesController extends PageController { } } if ($pedi && $pedi != 'birth') { - $indi_html = '<span class="red">' . WT_Gedcom_Code_Pedi::getValue($pedi, $individual) . '</span> ' . $indi_html; + $indi_html = '<span class="red">' . GedcomCodePedi::getValue($pedi, $individual) . '</span> ' . $indi_html; } } @@ -243,9 +243,9 @@ class BranchesController extends PageController { if ($marriage_year) { $fam_html .= ' <a href="' . $family->getHtmlUrl() . '" title="' . strip_tags($family->getMarriageDate()->display()) . '"><i class="icon-rings"></i>' . $marriage_year . '</a>'; } elseif ($family->getFirstFact('MARR')) { - $fam_html .= ' <a href="' . $family->getHtmlUrl() . '" title="' . WT_Gedcom_Tag::getLabel('MARR') . '"><i class="icon-rings"></i></a>'; + $fam_html .= ' <a href="' . $family->getHtmlUrl() . '" title="' . GedcomTag::getLabel('MARR') . '"><i class="icon-rings"></i></a>'; } elseif ($family->getFirstFact('_NMR')) { - $fam_html .= ' <a href="' . $family->getHtmlUrl() . '" title="' . WT_Gedcom_Tag::getLabel('_NMR') . '"><i class="icon-rings"></i></a>'; + $fam_html .= ' <a href="' . $family->getHtmlUrl() . '" title="' . GedcomTag::getLabel('_NMR') . '"><i class="icon-rings"></i></a>'; } $fam_html .= ' ' . $spouse->getSexImage() . '<a class="' . $sosa_class . '" href="' . $spouse->getHtmlUrl() . '">' . $spouse->getFullName() . '</a> ' . $spouse->getLifeSpan() . ' ' . $sosa_html; } diff --git a/app/Controller/DescendancyController.php b/app/Controller/DescendancyController.php index 91cbf20c7f..e4d71c39e2 100644 --- a/app/Controller/DescendancyController.php +++ b/app/Controller/DescendancyController.php @@ -201,12 +201,12 @@ class DescendancyController extends ChartController { $children = $family->getChildren(); echo '<tr><td colspan="3" class="details1" > '; if ($children) { - echo WT_Gedcom_Tag::getLabel('NCHI') . ': ' . count($children); + echo GedcomTag::getLabel('NCHI') . ': ' . count($children); } else { // Distinguish between no children (NCHI 0) and no recorded // children (no CHIL records) if (strpos($family->getGedcom(), '\n1 NCHI 0')) { - echo WT_Gedcom_Tag::getLabel('NCHI') . ': ' . count($children); + echo GedcomTag::getLabel('NCHI') . ': ' . count($children); } else { echo I18N::translate('No children'); } diff --git a/app/Controller/GedcomRecordController.php b/app/Controller/GedcomRecordController.php index f08c0911df..52430103f4 100644 --- a/app/Controller/GedcomRecordController.php +++ b/app/Controller/GedcomRecordController.php @@ -69,7 +69,7 @@ class GedcomRecordController extends PageController { } else { // e.g. "Individual" or "Source" $record = $this->record; - $this->setPageTitle(WT_Gedcom_Tag::getLabel($record::RECORD_TYPE)); + $this->setPageTitle(GedcomTag::getLabel($record::RECORD_TYPE)); } } else { // No such record diff --git a/app/Controller/IndividualController.php b/app/Controller/IndividualController.php index 5775ebb35e..e9f4ac29de 100644 --- a/app/Controller/IndividualController.php +++ b/app/Controller/IndividualController.php @@ -168,7 +168,7 @@ class IndividualController extends GedcomRecordController { echo '<div>'; $fact = $nmatch[$i][1]; if ($fact != 'SOUR' && $fact != 'NOTE' && $fact != 'SPFX') { - echo '<dl><dt class="label">', WT_Gedcom_Tag::getLabel($fact, $this->record), '</dt>'; + echo '<dl><dt class="label">', GedcomTag::getLabel($fact, $this->record), '</dt>'; echo '<dd class="field">'; // Before using dir="auto" on this field, note that Gecko treats this as an inline element but WebKit treats it as a block element if (isset($nmatch[$i][2])) { $name = Filter::escapeHtml($nmatch[$i][2]); @@ -176,7 +176,7 @@ class IndividualController extends GedcomRecordController { $name = preg_replace('/(\S*)\*/', '<span class="starredname">\\1</span>', $name); switch ($fact) { case 'TYPE': - echo WT_Gedcom_Code_Name::getValue($name, $this->record); + echo GedcomCodeName::getValue($name, $this->record); break; case 'SURN': // The SURN field is not necessarily the surname. @@ -246,10 +246,10 @@ class IndividualController extends GedcomRecordController { case 'U': echo 'unknown_gender"'; if ($event->canEdit()) { - echo ' title="', I18N::translate_c('unknown gender', 'Unknown'), ' - ', I18N::translate('Edit'), '"'; + echo ' title="', I18N::translateContext('unknown gender', 'Unknown'), ' - ', I18N::translate('Edit'), '"'; echo ' onclick="edit_record(\'' . $this->record->getXref() . '\', \'' . $event->getFactId() . '\'); return false;">'; } else { - echo ' title="', I18N::translate_c('unknown gender', 'Unknown'), '">'; + echo ' title="', I18N::translateContext('unknown gender', 'Unknown'), '">'; } break; } diff --git a/app/Controller/LifespanController.php b/app/Controller/LifespanController.php index 8586099e2b..a9cd95c913 100644 --- a/app/Controller/LifespanController.php +++ b/app/Controller/LifespanController.php @@ -443,7 +443,7 @@ class LifespanController extends PageController { if ($fact == "EVEN") { $fact = $val->getAttribute('TYPE'); } - $trans = WT_Gedcom_Tag::getLabel($fact); + $trans = GedcomTag::getLabel($fact); if (isset($eventinformation[$evntwdth])) { $eventinformation[$evntwdth] .= '<br>' . $trans . '<br>' . strip_tags($date->display()) . ' ' . $val->getPlace()->getFullName(); } else { @@ -465,7 +465,7 @@ class LifespanController extends PageController { $indiName = $value->getFullName(); echo '<table><tr><td width="15"><a class="showit" href="#"><b>'; echo self::getAbbreviation('BIRT'); - echo '</b><span>', $value->getSexImage(), $indiName, '<br>', WT_Gedcom_Tag::getLabel('BIRT'), ' ', strip_tags($bdate->display()), ' ', $value->getBirthPlace(), '</span></a>', + echo '</b><span>', $value->getSexImage(), $indiName, '<br>', GedcomTag::getLabel('BIRT'), ' ', strip_tags($bdate->display()), ' ', $value->getBirthPlace(), '</span></a>', '<td align="left" width="100%"><a href="', $value->getHtmlUrl(), '">', $value->getSexImage(), $indiName, ' ', $lifespan, ' </a></td>', '<td width="15">'; if ($value->isDead()) { @@ -475,7 +475,7 @@ class LifespanController extends PageController { if (!$deathReal) { echo '*'; } - echo '</b><span>' . $value->getSexImage() . $indiName . '<br>' . WT_Gedcom_Tag::getLabel('DEAT') . ' ' . strip_tags($ddate->display()) . ' ' . $value->getDeathPlace() . '</span></a>'; + echo '</b><span>' . $value->getSexImage() . $indiName . '<br>' . GedcomTag::getLabel('DEAT') . ' ' . strip_tags($ddate->display()) . ' ' . $value->getDeathPlace() . '</span></a>'; } } echo '</td></tr></table>'; @@ -495,7 +495,7 @@ class LifespanController extends PageController { if (!$birthReal) { echo '*'; } - echo '</b><span>' . $value->getSexImage() . $indiName . '<br>' . WT_Gedcom_Tag::getLabel('BIRT') . ' ' . strip_tags($bdate->display(false)) . ' ' . $value->getBirthPlace() . '</span></a></td>' . '<td align="left" width="100%"><a href="' . $value->getHtmlUrl() . '">' . $value->getSexImage() . $indiName . '</a></td>' . + echo '</b><span>' . $value->getSexImage() . $indiName . '<br>' . GedcomTag::getLabel('BIRT') . ' ' . strip_tags($bdate->display(false)) . ' ' . $value->getBirthPlace() . '</span></a></td>' . '<td align="left" width="100%"><a href="' . $value->getHtmlUrl() . '">' . $value->getSexImage() . $indiName . '</a></td>' . '<td width="15">'; if ($value->isDead()) { if ($deathReal || $value->isDead()) { @@ -504,7 +504,7 @@ class LifespanController extends PageController { if (!$deathReal) { echo "*"; } - echo '</b><span>' . $value->getSexImage() . $indiName . '<br>' . WT_Gedcom_Tag::getLabel('DEAT') . ' ' . strip_tags($ddate->display()) . ' ' . $value->getDeathPlace() . '</span></a>'; + echo '</b><span>' . $value->getSexImage() . $indiName . '<br>' . GedcomTag::getLabel('DEAT') . ' ' . strip_tags($ddate->display()) . ' ' . $value->getDeathPlace() . '</span></a>'; } } echo '</td></tr></table>'; @@ -514,14 +514,14 @@ class LifespanController extends PageController { $indiName = $value->getFullName(); echo '<a class="showit" href="' . $value->getHtmlUrl() . '"><b>'; echo self::getAbbreviation('BIRT'); - echo '</b><span>' . $value->getSexImage() . $indiName . '<br>' . WT_Gedcom_Tag::getLabel('BIRT') . ' ' . strip_tags($bdate->display()) . ' ' . $value->getBirthPlace() . '<br>'; + echo '</b><span>' . $value->getSexImage() . $indiName . '<br>' . GedcomTag::getLabel('BIRT') . ' ' . strip_tags($bdate->display()) . ' ' . $value->getBirthPlace() . '<br>'; foreach ($eventinformation as $val) { $text = explode('-fact,', $val); $val = $text[1]; echo $val . "<br>"; } if ($value->isDead() && $deathReal) { - echo WT_Gedcom_Tag::getLabel('DEAT') . " " . strip_tags($ddate->display()) . " " . $value->getDeathPlace(); + echo GedcomTag::getLabel('DEAT') . " " . strip_tags($ddate->display()) . " " . $value->getDeathPlace(); } echo '</span></a>'; echo '</div>'; @@ -594,13 +594,13 @@ class LifespanController extends PageController { private static function getAbbreviation($tag) { switch ($tag) { case 'BIRT': - return I18N::translate_c('Abbreviation for birth', 'b.'); + return I18N::translateContext('Abbreviation for birth', 'b.'); case 'MARR': - return I18N::translate_c('Abbreviation for marriage', 'm.'); + return I18N::translateContext('Abbreviation for marriage', 'm.'); case 'DEAT': - return I18N::translate_c('Abbreviation for death', 'd.'); + return I18N::translateContext('Abbreviation for death', 'd.'); default: - return mb_substr(WT_Gedcom_Tag::getLabel($tag), 0, 1); // Just use the first letter of the full fact + return mb_substr(GedcomTag::getLabel($tag), 0, 1); // Just use the first letter of the full fact } } } diff --git a/app/Controller/TimelineController.php b/app/Controller/TimelineController.php index 0267e12ada..c5beb034db 100644 --- a/app/Controller/TimelineController.php +++ b/app/Controller/TimelineController.php @@ -154,7 +154,7 @@ class TimelineController extends PageController { /** * @param Fact $event */ - function print_time_fact(Fact $event) { + public function printTimeFact(Fact $event) { global $basexoffset, $baseyoffset, $factcount, $placements; $desc = $event->getValue(); diff --git a/app/Date/CalendarDate.php b/app/Date/CalendarDate.php index 05fa05c6b3..479ce76656 100644 --- a/app/Date/CalendarDate.php +++ b/app/Date/CalendarDate.php @@ -189,18 +189,18 @@ class CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => I18N::translate_c('NOMINATIVE', 'January'), - 2 => I18N::translate_c('NOMINATIVE', 'February'), - 3 => I18N::translate_c('NOMINATIVE', 'March'), - 4 => I18N::translate_c('NOMINATIVE', 'April'), - 5 => I18N::translate_c('NOMINATIVE', 'May'), - 6 => I18N::translate_c('NOMINATIVE', 'June'), - 7 => I18N::translate_c('NOMINATIVE', 'July'), - 8 => I18N::translate_c('NOMINATIVE', 'August'), - 9 => I18N::translate_c('NOMINATIVE', 'September'), - 10 => I18N::translate_c('NOMINATIVE', 'October'), - 11 => I18N::translate_c('NOMINATIVE', 'November'), - 12 => I18N::translate_c('NOMINATIVE', 'December'), + 1 => I18N::translateContext('NOMINATIVE', 'January'), + 2 => I18N::translateContext('NOMINATIVE', 'February'), + 3 => I18N::translateContext('NOMINATIVE', 'March'), + 4 => I18N::translateContext('NOMINATIVE', 'April'), + 5 => I18N::translateContext('NOMINATIVE', 'May'), + 6 => I18N::translateContext('NOMINATIVE', 'June'), + 7 => I18N::translateContext('NOMINATIVE', 'July'), + 8 => I18N::translateContext('NOMINATIVE', 'August'), + 9 => I18N::translateContext('NOMINATIVE', 'September'), + 10 => I18N::translateContext('NOMINATIVE', 'October'), + 11 => I18N::translateContext('NOMINATIVE', 'November'), + 12 => I18N::translateContext('NOMINATIVE', 'December'), ); } @@ -223,18 +223,18 @@ class CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => I18N::translate_c('GENITIVE', 'January'), - 2 => I18N::translate_c('GENITIVE', 'February'), - 3 => I18N::translate_c('GENITIVE', 'March'), - 4 => I18N::translate_c('GENITIVE', 'April'), - 5 => I18N::translate_c('GENITIVE', 'May'), - 6 => I18N::translate_c('GENITIVE', 'June'), - 7 => I18N::translate_c('GENITIVE', 'July'), - 8 => I18N::translate_c('GENITIVE', 'August'), - 9 => I18N::translate_c('GENITIVE', 'September'), - 10 => I18N::translate_c('GENITIVE', 'October'), - 11 => I18N::translate_c('GENITIVE', 'November'), - 12 => I18N::translate_c('GENITIVE', 'December'), + 1 => I18N::translateContext('GENITIVE', 'January'), + 2 => I18N::translateContext('GENITIVE', 'February'), + 3 => I18N::translateContext('GENITIVE', 'March'), + 4 => I18N::translateContext('GENITIVE', 'April'), + 5 => I18N::translateContext('GENITIVE', 'May'), + 6 => I18N::translateContext('GENITIVE', 'June'), + 7 => I18N::translateContext('GENITIVE', 'July'), + 8 => I18N::translateContext('GENITIVE', 'August'), + 9 => I18N::translateContext('GENITIVE', 'September'), + 10 => I18N::translateContext('GENITIVE', 'October'), + 11 => I18N::translateContext('GENITIVE', 'November'), + 12 => I18N::translateContext('GENITIVE', 'December'), ); } @@ -257,18 +257,18 @@ class CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => I18N::translate_c('LOCATIVE', 'January'), - 2 => I18N::translate_c('LOCATIVE', 'February'), - 3 => I18N::translate_c('LOCATIVE', 'March'), - 4 => I18N::translate_c('LOCATIVE', 'April'), - 5 => I18N::translate_c('LOCATIVE', 'May'), - 6 => I18N::translate_c('LOCATIVE', 'June'), - 7 => I18N::translate_c('LOCATIVE', 'July'), - 8 => I18N::translate_c('LOCATIVE', 'August'), - 9 => I18N::translate_c('LOCATIVE', 'September'), - 10 => I18N::translate_c('LOCATIVE', 'October'), - 11 => I18N::translate_c('LOCATIVE', 'November'), - 12 => I18N::translate_c('LOCATIVE', 'December'), + 1 => I18N::translateContext('LOCATIVE', 'January'), + 2 => I18N::translateContext('LOCATIVE', 'February'), + 3 => I18N::translateContext('LOCATIVE', 'March'), + 4 => I18N::translateContext('LOCATIVE', 'April'), + 5 => I18N::translateContext('LOCATIVE', 'May'), + 6 => I18N::translateContext('LOCATIVE', 'June'), + 7 => I18N::translateContext('LOCATIVE', 'July'), + 8 => I18N::translateContext('LOCATIVE', 'August'), + 9 => I18N::translateContext('LOCATIVE', 'September'), + 10 => I18N::translateContext('LOCATIVE', 'October'), + 11 => I18N::translateContext('LOCATIVE', 'November'), + 12 => I18N::translateContext('LOCATIVE', 'December'), ); } @@ -291,18 +291,18 @@ class CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => I18N::translate_c('INSTRUMENTAL', 'January'), - 2 => I18N::translate_c('INSTRUMENTAL', 'February'), - 3 => I18N::translate_c('INSTRUMENTAL', 'March'), - 4 => I18N::translate_c('INSTRUMENTAL', 'April'), - 5 => I18N::translate_c('INSTRUMENTAL', 'May'), - 6 => I18N::translate_c('INSTRUMENTAL', 'June'), - 7 => I18N::translate_c('INSTRUMENTAL', 'July'), - 8 => I18N::translate_c('INSTRUMENTAL', 'August'), - 9 => I18N::translate_c('INSTRUMENTAL', 'September'), - 10 => I18N::translate_c('INSTRUMENTAL', 'October'), - 11 => I18N::translate_c('INSTRUMENTAL', 'November'), - 12 => I18N::translate_c('INSTRUMENTAL', 'December'), + 1 => I18N::translateContext('INSTRUMENTAL', 'January'), + 2 => I18N::translateContext('INSTRUMENTAL', 'February'), + 3 => I18N::translateContext('INSTRUMENTAL', 'March'), + 4 => I18N::translateContext('INSTRUMENTAL', 'April'), + 5 => I18N::translateContext('INSTRUMENTAL', 'May'), + 6 => I18N::translateContext('INSTRUMENTAL', 'June'), + 7 => I18N::translateContext('INSTRUMENTAL', 'July'), + 8 => I18N::translateContext('INSTRUMENTAL', 'August'), + 9 => I18N::translateContext('INSTRUMENTAL', 'September'), + 10 => I18N::translateContext('INSTRUMENTAL', 'October'), + 11 => I18N::translateContext('INSTRUMENTAL', 'November'), + 12 => I18N::translateContext('INSTRUMENTAL', 'December'), ); } @@ -323,18 +323,18 @@ class CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => I18N::translate_c('Abbreviation for January', 'Jan'), - 2 => I18N::translate_c('Abbreviation for February', 'Feb'), - 3 => I18N::translate_c('Abbreviation for March', 'Mar'), - 4 => I18N::translate_c('Abbreviation for April', 'Apr'), - 5 => I18N::translate_c('Abbreviation for May', 'May'), - 6 => I18N::translate_c('Abbreviation for June', 'Jun'), - 7 => I18N::translate_c('Abbreviation for July', 'Jul'), - 8 => I18N::translate_c('Abbreviation for August', 'Aug'), - 9 => I18N::translate_c('Abbreviation for September', 'Sep'), - 10 => I18N::translate_c('Abbreviation for October', 'Oct'), - 11 => I18N::translate_c('Abbreviation for November', 'Nov'), - 12 => I18N::translate_c('Abbreviation for December', 'Dec'), + 1 => I18N::translateContext('Abbreviation for January', 'Jan'), + 2 => I18N::translateContext('Abbreviation for February', 'Feb'), + 3 => I18N::translateContext('Abbreviation for March', 'Mar'), + 4 => I18N::translateContext('Abbreviation for April', 'Apr'), + 5 => I18N::translateContext('Abbreviation for May', 'May'), + 6 => I18N::translateContext('Abbreviation for June', 'Jun'), + 7 => I18N::translateContext('Abbreviation for July', 'Jul'), + 8 => I18N::translateContext('Abbreviation for August', 'Aug'), + 9 => I18N::translateContext('Abbreviation for September', 'Sep'), + 10 => I18N::translateContext('Abbreviation for October', 'Oct'), + 11 => I18N::translateContext('Abbreviation for November', 'Nov'), + 12 => I18N::translateContext('Abbreviation for December', 'Dec'), ); } diff --git a/app/Date/FrenchDate.php b/app/Date/FrenchDate.php index 90c907a06f..79e765d8e9 100644 --- a/app/Date/FrenchDate.php +++ b/app/Date/FrenchDate.php @@ -49,19 +49,19 @@ class FrenchDate extends CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => /* I18N: a month in the French republican calendar */ I18N::translate_c('NOMINATIVE', 'Vendémiaire'), - 2 => /* I18N: a month in the French republican calendar */ I18N::translate_c('NOMINATIVE', 'Brumaire'), - 3 => /* I18N: a month in the French republican calendar */ I18N::translate_c('NOMINATIVE', 'Frimaire'), - 4 => /* I18N: a month in the French republican calendar */ I18N::translate_c('NOMINATIVE', 'Nivôse'), - 5 => /* I18N: a month in the French republican calendar */ I18N::translate_c('NOMINATIVE', 'Pluviôse'), - 6 => /* I18N: a month in the French republican calendar */ I18N::translate_c('NOMINATIVE', 'Ventôse'), - 7 => /* I18N: a month in the French republican calendar */ I18N::translate_c('NOMINATIVE', 'Germinal'), - 8 => /* I18N: a month in the French republican calendar */ I18N::translate_c('NOMINATIVE', 'Floréal'), - 9 => /* I18N: a month in the French republican calendar */ I18N::translate_c('NOMINATIVE', 'Prairial'), - 10 => /* I18N: a month in the French republican calendar */ I18N::translate_c('NOMINATIVE', 'Messidor'), - 11 => /* I18N: a month in the French republican calendar */ I18N::translate_c('NOMINATIVE', 'Thermidor'), - 12 => /* I18N: a month in the French republican calendar */ I18N::translate_c('NOMINATIVE', 'Fructidor'), - 13 => /* I18N: a month in the French republican calendar */ I18N::translate_c('NOMINATIVE', 'jours complémentaires'), + 1 => /* I18N: a month in the French republican calendar */ I18N::translateContext('NOMINATIVE', 'Vendémiaire'), + 2 => /* I18N: a month in the French republican calendar */ I18N::translateContext('NOMINATIVE', 'Brumaire'), + 3 => /* I18N: a month in the French republican calendar */ I18N::translateContext('NOMINATIVE', 'Frimaire'), + 4 => /* I18N: a month in the French republican calendar */ I18N::translateContext('NOMINATIVE', 'Nivôse'), + 5 => /* I18N: a month in the French republican calendar */ I18N::translateContext('NOMINATIVE', 'Pluviôse'), + 6 => /* I18N: a month in the French republican calendar */ I18N::translateContext('NOMINATIVE', 'Ventôse'), + 7 => /* I18N: a month in the French republican calendar */ I18N::translateContext('NOMINATIVE', 'Germinal'), + 8 => /* I18N: a month in the French republican calendar */ I18N::translateContext('NOMINATIVE', 'Floréal'), + 9 => /* I18N: a month in the French republican calendar */ I18N::translateContext('NOMINATIVE', 'Prairial'), + 10 => /* I18N: a month in the French republican calendar */ I18N::translateContext('NOMINATIVE', 'Messidor'), + 11 => /* I18N: a month in the French republican calendar */ I18N::translateContext('NOMINATIVE', 'Thermidor'), + 12 => /* I18N: a month in the French republican calendar */ I18N::translateContext('NOMINATIVE', 'Fructidor'), + 13 => /* I18N: a month in the French republican calendar */ I18N::translateContext('NOMINATIVE', 'jours complémentaires'), ); } @@ -75,19 +75,19 @@ class FrenchDate extends CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => /* I18N: a month in the French republican calendar */ I18N::translate_c('GENITIVE', 'Vendémiaire'), - 2 => /* I18N: a month in the French republican calendar */ I18N::translate_c('GENITIVE', 'Brumaire'), - 3 => /* I18N: a month in the French republican calendar */ I18N::translate_c('GENITIVE', 'Frimaire'), - 4 => /* I18N: a month in the French republican calendar */ I18N::translate_c('GENITIVE', 'Nivôse'), - 5 => /* I18N: a month in the French republican calendar */ I18N::translate_c('GENITIVE', 'Pluviôse'), - 6 => /* I18N: a month in the French republican calendar */ I18N::translate_c('GENITIVE', 'Ventôse'), - 7 => /* I18N: a month in the French republican calendar */ I18N::translate_c('GENITIVE', 'Germinal'), - 8 => /* I18N: a month in the French republican calendar */ I18N::translate_c('GENITIVE', 'Floréal'), - 9 => /* I18N: a month in the French republican calendar */ I18N::translate_c('GENITIVE', 'Prairial'), - 10 => /* I18N: a month in the French republican calendar */ I18N::translate_c('GENITIVE', 'Messidor'), - 11 => /* I18N: a month in the French republican calendar */ I18N::translate_c('GENITIVE', 'Thermidor'), - 12 => /* I18N: a month in the French republican calendar */ I18N::translate_c('GENITIVE', 'Fructidor'), - 13 => /* I18N: a month in the French republican calendar */ I18N::translate_c('GENITIVE', 'jours complémentaires'), + 1 => /* I18N: a month in the French republican calendar */ I18N::translateContext('GENITIVE', 'Vendémiaire'), + 2 => /* I18N: a month in the French republican calendar */ I18N::translateContext('GENITIVE', 'Brumaire'), + 3 => /* I18N: a month in the French republican calendar */ I18N::translateContext('GENITIVE', 'Frimaire'), + 4 => /* I18N: a month in the French republican calendar */ I18N::translateContext('GENITIVE', 'Nivôse'), + 5 => /* I18N: a month in the French republican calendar */ I18N::translateContext('GENITIVE', 'Pluviôse'), + 6 => /* I18N: a month in the French republican calendar */ I18N::translateContext('GENITIVE', 'Ventôse'), + 7 => /* I18N: a month in the French republican calendar */ I18N::translateContext('GENITIVE', 'Germinal'), + 8 => /* I18N: a month in the French republican calendar */ I18N::translateContext('GENITIVE', 'Floréal'), + 9 => /* I18N: a month in the French republican calendar */ I18N::translateContext('GENITIVE', 'Prairial'), + 10 => /* I18N: a month in the French republican calendar */ I18N::translateContext('GENITIVE', 'Messidor'), + 11 => /* I18N: a month in the French republican calendar */ I18N::translateContext('GENITIVE', 'Thermidor'), + 12 => /* I18N: a month in the French republican calendar */ I18N::translateContext('GENITIVE', 'Fructidor'), + 13 => /* I18N: a month in the French republican calendar */ I18N::translateContext('GENITIVE', 'jours complémentaires'), ); } @@ -101,19 +101,19 @@ class FrenchDate extends CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => /* I18N: a month in the French republican calendar */ I18N::translate_c('LOCATIVE', 'Vendémiaire'), - 2 => /* I18N: a month in the French republican calendar */ I18N::translate_c('LOCATIVE', 'Brumaire'), - 3 => /* I18N: a month in the French republican calendar */ I18N::translate_c('LOCATIVE', 'Frimaire'), - 4 => /* I18N: a month in the French republican calendar */ I18N::translate_c('LOCATIVE', 'Nivôse'), - 5 => /* I18N: a month in the French republican calendar */ I18N::translate_c('LOCATIVE', 'Pluviôse'), - 6 => /* I18N: a month in the French republican calendar */ I18N::translate_c('LOCATIVE', 'Ventôse'), - 7 => /* I18N: a month in the French republican calendar */ I18N::translate_c('LOCATIVE', 'Germinal'), - 8 => /* I18N: a month in the French republican calendar */ I18N::translate_c('LOCATIVE', 'Floréal'), - 9 => /* I18N: a month in the French republican calendar */ I18N::translate_c('LOCATIVE', 'Prairial'), - 10 => /* I18N: a month in the French republican calendar */ I18N::translate_c('LOCATIVE', 'Messidor'), - 11 => /* I18N: a month in the French republican calendar */ I18N::translate_c('LOCATIVE', 'Thermidor'), - 12 => /* I18N: a month in the French republican calendar */ I18N::translate_c('LOCATIVE', 'Fructidor'), - 13 => /* I18N: a month in the French republican calendar */ I18N::translate_c('LOCATIVE', 'jours complémentaires'), + 1 => /* I18N: a month in the French republican calendar */ I18N::translateContext('LOCATIVE', 'Vendémiaire'), + 2 => /* I18N: a month in the French republican calendar */ I18N::translateContext('LOCATIVE', 'Brumaire'), + 3 => /* I18N: a month in the French republican calendar */ I18N::translateContext('LOCATIVE', 'Frimaire'), + 4 => /* I18N: a month in the French republican calendar */ I18N::translateContext('LOCATIVE', 'Nivôse'), + 5 => /* I18N: a month in the French republican calendar */ I18N::translateContext('LOCATIVE', 'Pluviôse'), + 6 => /* I18N: a month in the French republican calendar */ I18N::translateContext('LOCATIVE', 'Ventôse'), + 7 => /* I18N: a month in the French republican calendar */ I18N::translateContext('LOCATIVE', 'Germinal'), + 8 => /* I18N: a month in the French republican calendar */ I18N::translateContext('LOCATIVE', 'Floréal'), + 9 => /* I18N: a month in the French republican calendar */ I18N::translateContext('LOCATIVE', 'Prairial'), + 10 => /* I18N: a month in the French republican calendar */ I18N::translateContext('LOCATIVE', 'Messidor'), + 11 => /* I18N: a month in the French republican calendar */ I18N::translateContext('LOCATIVE', 'Thermidor'), + 12 => /* I18N: a month in the French republican calendar */ I18N::translateContext('LOCATIVE', 'Fructidor'), + 13 => /* I18N: a month in the French republican calendar */ I18N::translateContext('LOCATIVE', 'jours complémentaires'), ); } @@ -127,19 +127,19 @@ class FrenchDate extends CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => /* I18N: a month in the French republican calendar */ I18N::translate_c('INSTRUMENTAL', 'Vendémiaire'), - 2 => /* I18N: a month in the French republican calendar */ I18N::translate_c('INSTRUMENTAL', 'Brumaire'), - 3 => /* I18N: a month in the French republican calendar */ I18N::translate_c('INSTRUMENTAL', 'Frimaire'), - 4 => /* I18N: a month in the French republican calendar */ I18N::translate_c('INSTRUMENTAL', 'Nivôse'), - 5 => /* I18N: a month in the French republican calendar */ I18N::translate_c('INSTRUMENTAL', 'Pluviôse'), - 6 => /* I18N: a month in the French republican calendar */ I18N::translate_c('INSTRUMENTAL', 'Ventôse'), - 7 => /* I18N: a month in the French republican calendar */ I18N::translate_c('INSTRUMENTAL', 'Germinal'), - 8 => /* I18N: a month in the French republican calendar */ I18N::translate_c('INSTRUMENTAL', 'Floréal'), - 9 => /* I18N: a month in the French republican calendar */ I18N::translate_c('INSTRUMENTAL', 'Prairial'), - 10 => /* I18N: a month in the French republican calendar */ I18N::translate_c('INSTRUMENTAL', 'Messidor'), - 11 => /* I18N: a month in the French republican calendar */ I18N::translate_c('INSTRUMENTAL', 'Thermidor'), - 12 => /* I18N: a month in the French republican calendar */ I18N::translate_c('INSTRUMENTAL', 'Fructidor'), - 13 => /* I18N: a month in the French republican calendar */ I18N::translate_c('INSTRUMENTAL', 'jours complémentaires'), + 1 => /* I18N: a month in the French republican calendar */ I18N::translateContext('INSTRUMENTAL', 'Vendémiaire'), + 2 => /* I18N: a month in the French republican calendar */ I18N::translateContext('INSTRUMENTAL', 'Brumaire'), + 3 => /* I18N: a month in the French republican calendar */ I18N::translateContext('INSTRUMENTAL', 'Frimaire'), + 4 => /* I18N: a month in the French republican calendar */ I18N::translateContext('INSTRUMENTAL', 'Nivôse'), + 5 => /* I18N: a month in the French republican calendar */ I18N::translateContext('INSTRUMENTAL', 'Pluviôse'), + 6 => /* I18N: a month in the French republican calendar */ I18N::translateContext('INSTRUMENTAL', 'Ventôse'), + 7 => /* I18N: a month in the French republican calendar */ I18N::translateContext('INSTRUMENTAL', 'Germinal'), + 8 => /* I18N: a month in the French republican calendar */ I18N::translateContext('INSTRUMENTAL', 'Floréal'), + 9 => /* I18N: a month in the French republican calendar */ I18N::translateContext('INSTRUMENTAL', 'Prairial'), + 10 => /* I18N: a month in the French republican calendar */ I18N::translateContext('INSTRUMENTAL', 'Messidor'), + 11 => /* I18N: a month in the French republican calendar */ I18N::translateContext('INSTRUMENTAL', 'Thermidor'), + 12 => /* I18N: a month in the French republican calendar */ I18N::translateContext('INSTRUMENTAL', 'Fructidor'), + 13 => /* I18N: a month in the French republican calendar */ I18N::translateContext('INSTRUMENTAL', 'jours complémentaires'), ); } diff --git a/app/Date/HijriDate.php b/app/Date/HijriDate.php index fdf1ff8e43..a4693e0332 100644 --- a/app/Date/HijriDate.php +++ b/app/Date/HijriDate.php @@ -50,18 +50,18 @@ class HijriDate extends CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => /* I18N: http://en.wikipedia.org/wiki/Muharram */ I18N::translate_c('NOMINATIVE', 'Muharram'), - 2 => /* I18N: http://en.wikipedia.org/wiki/Safar */ I18N::translate_c('NOMINATIVE', 'Safar'), - 3 => /* I18N: http://en.wikipedia.org/wiki/Rabi%27_al-awwal */ I18N::translate_c('NOMINATIVE', 'Rabi’ al-awwal'), - 4 => /* I18N: http://en.wikipedia.org/wiki/Rabi%27_al-thani */ I18N::translate_c('NOMINATIVE', 'Rabi’ al-thani'), - 5 => /* I18N: http://en.wikipedia.org/wiki/Jumada_al-awwal */ I18N::translate_c('NOMINATIVE', 'Jumada al-awwal'), - 6 => /* I18N: http://en.wikipedia.org/wiki/Jumada_al-thani */ I18N::translate_c('NOMINATIVE', 'Jumada al-thani'), - 7 => /* I18N: http://en.wikipedia.org/wiki/Rajab */ I18N::translate_c('NOMINATIVE', 'Rajab'), - 8 => /* I18N: http://en.wikipedia.org/wiki/Sha%27aban */ I18N::translate_c('NOMINATIVE', 'Sha’aban'), - 9 => /* I18N: http://en.wikipedia.org/wiki/Ramadan_%28calendar_month%29 */ I18N::translate_c('NOMINATIVE', 'Ramadan'), - 10 => /* I18N: http://en.wikipedia.org/wiki/Shawwal */ I18N::translate_c('NOMINATIVE', 'Shawwal'), - 11 => /* I18N: http://en.wikipedia.org/wiki/Dhu_al-Qi%27dah */ I18N::translate_c('NOMINATIVE', 'Dhu al-Qi’dah'), - 12 => /* I18N: http://en.wikipedia.org/wiki/Dhu_al-Hijjah */ I18N::translate_c('NOMINATIVE', 'Dhu al-Hijjah'), + 1 => /* I18N: http://en.wikipedia.org/wiki/Muharram */ I18N::translateContext('NOMINATIVE', 'Muharram'), + 2 => /* I18N: http://en.wikipedia.org/wiki/Safar */ I18N::translateContext('NOMINATIVE', 'Safar'), + 3 => /* I18N: http://en.wikipedia.org/wiki/Rabi%27_al-awwal */ I18N::translateContext('NOMINATIVE', 'Rabi’ al-awwal'), + 4 => /* I18N: http://en.wikipedia.org/wiki/Rabi%27_al-thani */ I18N::translateContext('NOMINATIVE', 'Rabi’ al-thani'), + 5 => /* I18N: http://en.wikipedia.org/wiki/Jumada_al-awwal */ I18N::translateContext('NOMINATIVE', 'Jumada al-awwal'), + 6 => /* I18N: http://en.wikipedia.org/wiki/Jumada_al-thani */ I18N::translateContext('NOMINATIVE', 'Jumada al-thani'), + 7 => /* I18N: http://en.wikipedia.org/wiki/Rajab */ I18N::translateContext('NOMINATIVE', 'Rajab'), + 8 => /* I18N: http://en.wikipedia.org/wiki/Sha%27aban */ I18N::translateContext('NOMINATIVE', 'Sha’aban'), + 9 => /* I18N: http://en.wikipedia.org/wiki/Ramadan_%28calendar_month%29 */ I18N::translateContext('NOMINATIVE', 'Ramadan'), + 10 => /* I18N: http://en.wikipedia.org/wiki/Shawwal */ I18N::translateContext('NOMINATIVE', 'Shawwal'), + 11 => /* I18N: http://en.wikipedia.org/wiki/Dhu_al-Qi%27dah */ I18N::translateContext('NOMINATIVE', 'Dhu al-Qi’dah'), + 12 => /* I18N: http://en.wikipedia.org/wiki/Dhu_al-Hijjah */ I18N::translateContext('NOMINATIVE', 'Dhu al-Hijjah'), ); } @@ -75,18 +75,18 @@ class HijriDate extends CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => /* I18N: http://en.wikipedia.org/wiki/Muharram */ I18N::translate_c('GENITIVE', 'Muharram'), - 2 => /* I18N: http://en.wikipedia.org/wiki/Safar */ I18N::translate_c('GENITIVE', 'Safar'), - 3 => /* I18N: http://en.wikipedia.org/wiki/Rabi%27_al-awwal */ I18N::translate_c('GENITIVE', 'Rabi’ al-awwal'), - 4 => /* I18N: http://en.wikipedia.org/wiki/Rabi%27_al-thani */ I18N::translate_c('GENITIVE', 'Rabi’ al-thani'), - 5 => /* I18N: http://en.wikipedia.org/wiki/Jumada_al-awwal */ I18N::translate_c('GENITIVE', 'Jumada al-awwal'), - 6 => /* I18N: http://en.wikipedia.org/wiki/Jumada_al-thani */ I18N::translate_c('GENITIVE', 'Jumada al-thani'), - 7 => /* I18N: http://en.wikipedia.org/wiki/Rajab */ I18N::translate_c('GENITIVE', 'Rajab'), - 8 => /* I18N: http://en.wikipedia.org/wiki/Sha%27aban */ I18N::translate_c('GENITIVE', 'Sha’aban'), - 9 => /* I18N: http://en.wikipedia.org/wiki/Ramadan_%28calendar_month%29 */ I18N::translate_c('GENITIVE', 'Ramadan'), - 10 => /* I18N: http://en.wikipedia.org/wiki/Shawwal */ I18N::translate_c('GENITIVE', 'Shawwal'), - 11 => /* I18N: http://en.wikipedia.org/wiki/Dhu_al-Qi%27dah */ I18N::translate_c('GENITIVE', 'Dhu al-Qi’dah'), - 12 => /* I18N: http://en.wikipedia.org/wiki/Dhu_al-Hijjah */ I18N::translate_c('GENITIVE', 'Dhu al-Hijjah'), + 1 => /* I18N: http://en.wikipedia.org/wiki/Muharram */ I18N::translateContext('GENITIVE', 'Muharram'), + 2 => /* I18N: http://en.wikipedia.org/wiki/Safar */ I18N::translateContext('GENITIVE', 'Safar'), + 3 => /* I18N: http://en.wikipedia.org/wiki/Rabi%27_al-awwal */ I18N::translateContext('GENITIVE', 'Rabi’ al-awwal'), + 4 => /* I18N: http://en.wikipedia.org/wiki/Rabi%27_al-thani */ I18N::translateContext('GENITIVE', 'Rabi’ al-thani'), + 5 => /* I18N: http://en.wikipedia.org/wiki/Jumada_al-awwal */ I18N::translateContext('GENITIVE', 'Jumada al-awwal'), + 6 => /* I18N: http://en.wikipedia.org/wiki/Jumada_al-thani */ I18N::translateContext('GENITIVE', 'Jumada al-thani'), + 7 => /* I18N: http://en.wikipedia.org/wiki/Rajab */ I18N::translateContext('GENITIVE', 'Rajab'), + 8 => /* I18N: http://en.wikipedia.org/wiki/Sha%27aban */ I18N::translateContext('GENITIVE', 'Sha’aban'), + 9 => /* I18N: http://en.wikipedia.org/wiki/Ramadan_%28calendar_month%29 */ I18N::translateContext('GENITIVE', 'Ramadan'), + 10 => /* I18N: http://en.wikipedia.org/wiki/Shawwal */ I18N::translateContext('GENITIVE', 'Shawwal'), + 11 => /* I18N: http://en.wikipedia.org/wiki/Dhu_al-Qi%27dah */ I18N::translateContext('GENITIVE', 'Dhu al-Qi’dah'), + 12 => /* I18N: http://en.wikipedia.org/wiki/Dhu_al-Hijjah */ I18N::translateContext('GENITIVE', 'Dhu al-Hijjah'), ); } @@ -100,18 +100,18 @@ class HijriDate extends CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => /* I18N: http://en.wikipedia.org/wiki/Muharram */ I18N::translate_c('LOCATIVE', 'Muharram'), - 2 => /* I18N: http://en.wikipedia.org/wiki/Safar */ I18N::translate_c('LOCATIVE', 'Safar'), - 3 => /* I18N: http://en.wikipedia.org/wiki/Rabi%27_al-awwal */ I18N::translate_c('LOCATIVE', 'Rabi’ al-awwal'), - 4 => /* I18N: http://en.wikipedia.org/wiki/Rabi%27_al-thani */ I18N::translate_c('LOCATIVE', 'Rabi’ al-thani'), - 5 => /* I18N: http://en.wikipedia.org/wiki/Jumada_al-awwal */ I18N::translate_c('LOCATIVE', 'Jumada al-awwal'), - 6 => /* I18N: http://en.wikipedia.org/wiki/Jumada_al-thani */ I18N::translate_c('LOCATIVE', 'Jumada al-thani'), - 7 => /* I18N: http://en.wikipedia.org/wiki/Rajab */ I18N::translate_c('LOCATIVE', 'Rajab'), - 8 => /* I18N: http://en.wikipedia.org/wiki/Sha%27aban */ I18N::translate_c('LOCATIVE', 'Sha’aban'), - 9 => /* I18N: http://en.wikipedia.org/wiki/Ramadan_%28calendar_month%29 */ I18N::translate_c('LOCATIVE', 'Ramadan'), - 10 => /* I18N: http://en.wikipedia.org/wiki/Shawwal */ I18N::translate_c('LOCATIVE', 'Shawwal'), - 11 => /* I18N: http://en.wikipedia.org/wiki/Dhu_al-Qi%27dah */ I18N::translate_c('LOCATIVE', 'Dhu al-Qi’dah'), - 12 => /* I18N: http://en.wikipedia.org/wiki/Dhu_al-Hijjah */ I18N::translate_c('LOCATIVE', 'Dhu al-Hijjah'), + 1 => /* I18N: http://en.wikipedia.org/wiki/Muharram */ I18N::translateContext('LOCATIVE', 'Muharram'), + 2 => /* I18N: http://en.wikipedia.org/wiki/Safar */ I18N::translateContext('LOCATIVE', 'Safar'), + 3 => /* I18N: http://en.wikipedia.org/wiki/Rabi%27_al-awwal */ I18N::translateContext('LOCATIVE', 'Rabi’ al-awwal'), + 4 => /* I18N: http://en.wikipedia.org/wiki/Rabi%27_al-thani */ I18N::translateContext('LOCATIVE', 'Rabi’ al-thani'), + 5 => /* I18N: http://en.wikipedia.org/wiki/Jumada_al-awwal */ I18N::translateContext('LOCATIVE', 'Jumada al-awwal'), + 6 => /* I18N: http://en.wikipedia.org/wiki/Jumada_al-thani */ I18N::translateContext('LOCATIVE', 'Jumada al-thani'), + 7 => /* I18N: http://en.wikipedia.org/wiki/Rajab */ I18N::translateContext('LOCATIVE', 'Rajab'), + 8 => /* I18N: http://en.wikipedia.org/wiki/Sha%27aban */ I18N::translateContext('LOCATIVE', 'Sha’aban'), + 9 => /* I18N: http://en.wikipedia.org/wiki/Ramadan_%28calendar_month%29 */ I18N::translateContext('LOCATIVE', 'Ramadan'), + 10 => /* I18N: http://en.wikipedia.org/wiki/Shawwal */ I18N::translateContext('LOCATIVE', 'Shawwal'), + 11 => /* I18N: http://en.wikipedia.org/wiki/Dhu_al-Qi%27dah */ I18N::translateContext('LOCATIVE', 'Dhu al-Qi’dah'), + 12 => /* I18N: http://en.wikipedia.org/wiki/Dhu_al-Hijjah */ I18N::translateContext('LOCATIVE', 'Dhu al-Hijjah'), ); } @@ -125,18 +125,18 @@ class HijriDate extends CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => /* I18N: http://en.wikipedia.org/wiki/Muharram */ I18N::translate_c('INSTRUMENTAL', 'Muharram'), - 2 => /* I18N: http://en.wikipedia.org/wiki/Safar */ I18N::translate_c('INSTRUMENTAL', 'Safar'), - 3 => /* I18N: http://en.wikipedia.org/wiki/Rabi%27_al-awwal */ I18N::translate_c('INSTRUMENTAL', 'Rabi’ al-awwal'), - 4 => /* I18N: http://en.wikipedia.org/wiki/Rabi%27_al-thani */ I18N::translate_c('INSTRUMENTAL', 'Rabi’ al-thani'), - 5 => /* I18N: http://en.wikipedia.org/wiki/Jumada_al-awwal */ I18N::translate_c('INSTRUMENTAL', 'Jumada al-awwal'), - 6 => /* I18N: http://en.wikipedia.org/wiki/Jumada_al-thani */ I18N::translate_c('INSTRUMENTAL', 'Jumada al-thani'), - 7 => /* I18N: http://en.wikipedia.org/wiki/Rajab */ I18N::translate_c('INSTRUMENTAL', 'Rajab'), - 8 => /* I18N: http://en.wikipedia.org/wiki/Sha%27aban */ I18N::translate_c('INSTRUMENTAL', 'Sha’aban'), - 9 => /* I18N: http://en.wikipedia.org/wiki/Ramadan_%28calendar_month%29 */ I18N::translate_c('INSTRUMENTAL', 'Ramadan'), - 10 => /* I18N: http://en.wikipedia.org/wiki/Shawwal */ I18N::translate_c('INSTRUMENTAL', 'Shawwal'), - 11 => /* I18N: http://en.wikipedia.org/wiki/Dhu_al-Qi%27dah */ I18N::translate_c('INSTRUMENTAL', 'Dhu al-Qi’dah'), - 12 => /* I18N: http://en.wikipedia.org/wiki/Dhu_al-Hijjah */ I18N::translate_c('INSTRUMENTAL', 'Dhu al-Hijjah'), + 1 => /* I18N: http://en.wikipedia.org/wiki/Muharram */ I18N::translateContext('INSTRUMENTAL', 'Muharram'), + 2 => /* I18N: http://en.wikipedia.org/wiki/Safar */ I18N::translateContext('INSTRUMENTAL', 'Safar'), + 3 => /* I18N: http://en.wikipedia.org/wiki/Rabi%27_al-awwal */ I18N::translateContext('INSTRUMENTAL', 'Rabi’ al-awwal'), + 4 => /* I18N: http://en.wikipedia.org/wiki/Rabi%27_al-thani */ I18N::translateContext('INSTRUMENTAL', 'Rabi’ al-thani'), + 5 => /* I18N: http://en.wikipedia.org/wiki/Jumada_al-awwal */ I18N::translateContext('INSTRUMENTAL', 'Jumada al-awwal'), + 6 => /* I18N: http://en.wikipedia.org/wiki/Jumada_al-thani */ I18N::translateContext('INSTRUMENTAL', 'Jumada al-thani'), + 7 => /* I18N: http://en.wikipedia.org/wiki/Rajab */ I18N::translateContext('INSTRUMENTAL', 'Rajab'), + 8 => /* I18N: http://en.wikipedia.org/wiki/Sha%27aban */ I18N::translateContext('INSTRUMENTAL', 'Sha’aban'), + 9 => /* I18N: http://en.wikipedia.org/wiki/Ramadan_%28calendar_month%29 */ I18N::translateContext('INSTRUMENTAL', 'Ramadan'), + 10 => /* I18N: http://en.wikipedia.org/wiki/Shawwal */ I18N::translateContext('INSTRUMENTAL', 'Shawwal'), + 11 => /* I18N: http://en.wikipedia.org/wiki/Dhu_al-Qi%27dah */ I18N::translateContext('INSTRUMENTAL', 'Dhu al-Qi’dah'), + 12 => /* I18N: http://en.wikipedia.org/wiki/Dhu_al-Hijjah */ I18N::translateContext('INSTRUMENTAL', 'Dhu al-Hijjah'), ); } diff --git a/app/Date/JalaliDate.php b/app/Date/JalaliDate.php index 6827dc8a6c..78e02381f4 100644 --- a/app/Date/JalaliDate.php +++ b/app/Date/JalaliDate.php @@ -47,18 +47,18 @@ class JalaliDate extends CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => /* I18N: 1st month in the Persian/Jalali calendar */ I18N::translate_c('NOMINATIVE', 'Farvardin'), - 2 => /* I18N: 2nd month in the Persian/Jalali calendar */ I18N::translate_c('NOMINATIVE', 'Ordibehesht'), - 3 => /* I18N: 3rd month in the Persian/Jalali calendar */ I18N::translate_c('NOMINATIVE', 'Khordad'), - 4 => /* I18N: 4th month in the Persian/Jalali calendar */ I18N::translate_c('NOMINATIVE', 'Tir'), - 5 => /* I18N: 5th month in the Persian/Jalali calendar */ I18N::translate_c('NOMINATIVE', 'Mordad'), - 6 => /* I18N: 6th month in the Persian/Jalali calendar */ I18N::translate_c('NOMINATIVE', 'Shahrivar'), - 7 => /* I18N: 7th month in the Persian/Jalali calendar */ I18N::translate_c('NOMINATIVE', 'Mehr'), - 8 => /* I18N: 8th month in the Persian/Jalali calendar */ I18N::translate_c('NOMINATIVE', 'Aban'), - 9 => /* I18N: 9th month in the Persian/Jalali calendar */ I18N::translate_c('NOMINATIVE', 'Azar'), - 10 => /* I18N: 10th month in the Persian/Jalali calendar */ I18N::translate_c('NOMINATIVE', 'Dey'), - 11 => /* I18N: 11th month in the Persian/Jalali calendar */ I18N::translate_c('NOMINATIVE', 'Bahman'), - 12 => /* I18N: 12th month in the Persian/Jalali calendar */ I18N::translate_c('NOMINATIVE', 'Esfand'), + 1 => /* I18N: 1st month in the Persian/Jalali calendar */ I18N::translateContext('NOMINATIVE', 'Farvardin'), + 2 => /* I18N: 2nd month in the Persian/Jalali calendar */ I18N::translateContext('NOMINATIVE', 'Ordibehesht'), + 3 => /* I18N: 3rd month in the Persian/Jalali calendar */ I18N::translateContext('NOMINATIVE', 'Khordad'), + 4 => /* I18N: 4th month in the Persian/Jalali calendar */ I18N::translateContext('NOMINATIVE', 'Tir'), + 5 => /* I18N: 5th month in the Persian/Jalali calendar */ I18N::translateContext('NOMINATIVE', 'Mordad'), + 6 => /* I18N: 6th month in the Persian/Jalali calendar */ I18N::translateContext('NOMINATIVE', 'Shahrivar'), + 7 => /* I18N: 7th month in the Persian/Jalali calendar */ I18N::translateContext('NOMINATIVE', 'Mehr'), + 8 => /* I18N: 8th month in the Persian/Jalali calendar */ I18N::translateContext('NOMINATIVE', 'Aban'), + 9 => /* I18N: 9th month in the Persian/Jalali calendar */ I18N::translateContext('NOMINATIVE', 'Azar'), + 10 => /* I18N: 10th month in the Persian/Jalali calendar */ I18N::translateContext('NOMINATIVE', 'Dey'), + 11 => /* I18N: 11th month in the Persian/Jalali calendar */ I18N::translateContext('NOMINATIVE', 'Bahman'), + 12 => /* I18N: 12th month in the Persian/Jalali calendar */ I18N::translateContext('NOMINATIVE', 'Esfand'), ); } @@ -72,18 +72,18 @@ class JalaliDate extends CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => /* I18N: 1st month in the Persian/Jalali calendar */ I18N::translate_c('GENITIVE', 'Farvardin'), - 2 => /* I18N: 2nd month in the Persian/Jalali calendar */ I18N::translate_c('GENITIVE', 'Ordibehesht'), - 3 => /* I18N: 3rd month in the Persian/Jalali calendar */ I18N::translate_c('GENITIVE', 'Khordad'), - 4 => /* I18N: 4th month in the Persian/Jalali calendar */ I18N::translate_c('GENITIVE', 'Tir'), - 5 => /* I18N: 5th month in the Persian/Jalali calendar */ I18N::translate_c('GENITIVE', 'Mordad'), - 6 => /* I18N: 6th month in the Persian/Jalali calendar */ I18N::translate_c('GENITIVE', 'Shahrivar'), - 7 => /* I18N: 7th month in the Persian/Jalali calendar */ I18N::translate_c('GENITIVE', 'Mehr'), - 8 => /* I18N: 8th month in the Persian/Jalali calendar */ I18N::translate_c('GENITIVE', 'Aban'), - 9 => /* I18N: 9th month in the Persian/Jalali calendar */ I18N::translate_c('GENITIVE', 'Azar'), - 10 => /* I18N: 10th month in the Persian/Jalali calendar */ I18N::translate_c('GENITIVE', 'Dey'), - 11 => /* I18N: 11th month in the Persian/Jalali calendar */ I18N::translate_c('GENITIVE', 'Bahman'), - 12 => /* I18N: 12th month in the Persian/Jalali calendar */ I18N::translate_c('GENITIVE', 'Esfand'), + 1 => /* I18N: 1st month in the Persian/Jalali calendar */ I18N::translateContext('GENITIVE', 'Farvardin'), + 2 => /* I18N: 2nd month in the Persian/Jalali calendar */ I18N::translateContext('GENITIVE', 'Ordibehesht'), + 3 => /* I18N: 3rd month in the Persian/Jalali calendar */ I18N::translateContext('GENITIVE', 'Khordad'), + 4 => /* I18N: 4th month in the Persian/Jalali calendar */ I18N::translateContext('GENITIVE', 'Tir'), + 5 => /* I18N: 5th month in the Persian/Jalali calendar */ I18N::translateContext('GENITIVE', 'Mordad'), + 6 => /* I18N: 6th month in the Persian/Jalali calendar */ I18N::translateContext('GENITIVE', 'Shahrivar'), + 7 => /* I18N: 7th month in the Persian/Jalali calendar */ I18N::translateContext('GENITIVE', 'Mehr'), + 8 => /* I18N: 8th month in the Persian/Jalali calendar */ I18N::translateContext('GENITIVE', 'Aban'), + 9 => /* I18N: 9th month in the Persian/Jalali calendar */ I18N::translateContext('GENITIVE', 'Azar'), + 10 => /* I18N: 10th month in the Persian/Jalali calendar */ I18N::translateContext('GENITIVE', 'Dey'), + 11 => /* I18N: 11th month in the Persian/Jalali calendar */ I18N::translateContext('GENITIVE', 'Bahman'), + 12 => /* I18N: 12th month in the Persian/Jalali calendar */ I18N::translateContext('GENITIVE', 'Esfand'), ); } @@ -97,18 +97,18 @@ class JalaliDate extends CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => /* I18N: 1st month in the Persian/Jalali calendar */ I18N::translate_c('LOCATIVE', 'Farvardin'), - 2 => /* I18N: 2nd month in the Persian/Jalali calendar */ I18N::translate_c('LOCATIVE', 'Ordibehesht'), - 3 => /* I18N: 3rd month in the Persian/Jalali calendar */ I18N::translate_c('LOCATIVE', 'Khordad'), - 4 => /* I18N: 4th month in the Persian/Jalali calendar */ I18N::translate_c('LOCATIVE', 'Tir'), - 5 => /* I18N: 5th month in the Persian/Jalali calendar */ I18N::translate_c('LOCATIVE', 'Mordad'), - 6 => /* I18N: 6th month in the Persian/Jalali calendar */ I18N::translate_c('LOCATIVE', 'Shahrivar'), - 7 => /* I18N: 7th month in the Persian/Jalali calendar */ I18N::translate_c('LOCATIVE', 'Mehr'), - 8 => /* I18N: 8th month in the Persian/Jalali calendar */ I18N::translate_c('LOCATIVE', 'Aban'), - 9 => /* I18N: 9th month in the Persian/Jalali calendar */ I18N::translate_c('LOCATIVE', 'Azar'), - 10 => /* I18N: 10th month in the Persian/Jalali calendar */ I18N::translate_c('LOCATIVE', 'Dey'), - 11 => /* I18N: 11th month in the Persian/Jalali calendar */ I18N::translate_c('LOCATIVE', 'Bahman'), - 12 => /* I18N: 12th month in the Persian/Jalali calendar */ I18N::translate_c('LOCATIVE', 'Esfand'), + 1 => /* I18N: 1st month in the Persian/Jalali calendar */ I18N::translateContext('LOCATIVE', 'Farvardin'), + 2 => /* I18N: 2nd month in the Persian/Jalali calendar */ I18N::translateContext('LOCATIVE', 'Ordibehesht'), + 3 => /* I18N: 3rd month in the Persian/Jalali calendar */ I18N::translateContext('LOCATIVE', 'Khordad'), + 4 => /* I18N: 4th month in the Persian/Jalali calendar */ I18N::translateContext('LOCATIVE', 'Tir'), + 5 => /* I18N: 5th month in the Persian/Jalali calendar */ I18N::translateContext('LOCATIVE', 'Mordad'), + 6 => /* I18N: 6th month in the Persian/Jalali calendar */ I18N::translateContext('LOCATIVE', 'Shahrivar'), + 7 => /* I18N: 7th month in the Persian/Jalali calendar */ I18N::translateContext('LOCATIVE', 'Mehr'), + 8 => /* I18N: 8th month in the Persian/Jalali calendar */ I18N::translateContext('LOCATIVE', 'Aban'), + 9 => /* I18N: 9th month in the Persian/Jalali calendar */ I18N::translateContext('LOCATIVE', 'Azar'), + 10 => /* I18N: 10th month in the Persian/Jalali calendar */ I18N::translateContext('LOCATIVE', 'Dey'), + 11 => /* I18N: 11th month in the Persian/Jalali calendar */ I18N::translateContext('LOCATIVE', 'Bahman'), + 12 => /* I18N: 12th month in the Persian/Jalali calendar */ I18N::translateContext('LOCATIVE', 'Esfand'), ); } @@ -122,18 +122,18 @@ class JalaliDate extends CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => /* I18N: 1st month in the Persian/Jalali calendar */ I18N::translate_c('INSTRUMENTAL', 'Farvardin'), - 2 => /* I18N: 2nd month in the Persian/Jalali calendar */ I18N::translate_c('INSTRUMENTAL', 'Ordibehesht'), - 3 => /* I18N: 3rd month in the Persian/Jalali calendar */ I18N::translate_c('INSTRUMENTAL', 'Khordad'), - 4 => /* I18N: 4th month in the Persian/Jalali calendar */ I18N::translate_c('INSTRUMENTAL', 'Tir'), - 5 => /* I18N: 5th month in the Persian/Jalali calendar */ I18N::translate_c('INSTRUMENTAL', 'Mordad'), - 6 => /* I18N: 6th month in the Persian/Jalali calendar */ I18N::translate_c('INSTRUMENTAL', 'Shahrivar'), - 7 => /* I18N: 7th month in the Persian/Jalali calendar */ I18N::translate_c('INSTRUMENTAL', 'Mehr'), - 8 => /* I18N: 8th month in the Persian/Jalali calendar */ I18N::translate_c('INSTRUMENTAL', 'Aban'), - 9 => /* I18N: 9th month in the Persian/Jalali calendar */ I18N::translate_c('INSTRUMENTAL', 'Azar'), - 10 => /* I18N: 10th month in the Persian/Jalali calendar */ I18N::translate_c('INSTRUMENTAL', 'Dey'), - 11 => /* I18N: 11th month in the Persian/Jalali calendar */ I18N::translate_c('INSTRUMENTAL', 'Bahman'), - 12 => /* I18N: 12th month in the Persian/Jalali calendar */ I18N::translate_c('INSTRUMENTAL', 'Esfand'), + 1 => /* I18N: 1st month in the Persian/Jalali calendar */ I18N::translateContext('INSTRUMENTAL', 'Farvardin'), + 2 => /* I18N: 2nd month in the Persian/Jalali calendar */ I18N::translateContext('INSTRUMENTAL', 'Ordibehesht'), + 3 => /* I18N: 3rd month in the Persian/Jalali calendar */ I18N::translateContext('INSTRUMENTAL', 'Khordad'), + 4 => /* I18N: 4th month in the Persian/Jalali calendar */ I18N::translateContext('INSTRUMENTAL', 'Tir'), + 5 => /* I18N: 5th month in the Persian/Jalali calendar */ I18N::translateContext('INSTRUMENTAL', 'Mordad'), + 6 => /* I18N: 6th month in the Persian/Jalali calendar */ I18N::translateContext('INSTRUMENTAL', 'Shahrivar'), + 7 => /* I18N: 7th month in the Persian/Jalali calendar */ I18N::translateContext('INSTRUMENTAL', 'Mehr'), + 8 => /* I18N: 8th month in the Persian/Jalali calendar */ I18N::translateContext('INSTRUMENTAL', 'Aban'), + 9 => /* I18N: 9th month in the Persian/Jalali calendar */ I18N::translateContext('INSTRUMENTAL', 'Azar'), + 10 => /* I18N: 10th month in the Persian/Jalali calendar */ I18N::translateContext('INSTRUMENTAL', 'Dey'), + 11 => /* I18N: 11th month in the Persian/Jalali calendar */ I18N::translateContext('INSTRUMENTAL', 'Bahman'), + 12 => /* I18N: 12th month in the Persian/Jalali calendar */ I18N::translateContext('INSTRUMENTAL', 'Esfand'), ); } @@ -147,18 +147,18 @@ class JalaliDate extends CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => I18N::translate_c('Abbreviation for Persian month: Farvardin', 'Far'), - 2 => I18N::translate_c('Abbreviation for Persian month: Ordibehesht', 'Ord'), - 3 => I18N::translate_c('Abbreviation for Persian month: Khordad', 'Khor'), - 4 => I18N::translate_c('Abbreviation for Persian month: Tir', 'Tir'), - 5 => I18N::translate_c('Abbreviation for Persian month: Mordad', 'Mor'), - 6 => I18N::translate_c('Abbreviation for Persian month: Shahrivar', 'Shah'), - 7 => I18N::translate_c('Abbreviation for Persian month: Mehr', 'Mehr'), - 8 => I18N::translate_c('Abbreviation for Persian month: Aban', 'Aban'), - 9 => I18N::translate_c('Abbreviation for Persian month: Azar', 'Azar'), - 10 => I18N::translate_c('Abbreviation for Persian month: Dey', 'Dey'), - 11 => I18N::translate_c('Abbreviation for Persian month: Bahman', 'Bah'), - 12 => I18N::translate_c('Abbreviation for Persian month: Esfand', 'Esf'), + 1 => I18N::translateContext('Abbreviation for Persian month: Farvardin', 'Far'), + 2 => I18N::translateContext('Abbreviation for Persian month: Ordibehesht', 'Ord'), + 3 => I18N::translateContext('Abbreviation for Persian month: Khordad', 'Khor'), + 4 => I18N::translateContext('Abbreviation for Persian month: Tir', 'Tir'), + 5 => I18N::translateContext('Abbreviation for Persian month: Mordad', 'Mor'), + 6 => I18N::translateContext('Abbreviation for Persian month: Shahrivar', 'Shah'), + 7 => I18N::translateContext('Abbreviation for Persian month: Mehr', 'Mehr'), + 8 => I18N::translateContext('Abbreviation for Persian month: Aban', 'Aban'), + 9 => I18N::translateContext('Abbreviation for Persian month: Azar', 'Azar'), + 10 => I18N::translateContext('Abbreviation for Persian month: Dey', 'Dey'), + 11 => I18N::translateContext('Abbreviation for Persian month: Bahman', 'Bah'), + 12 => I18N::translateContext('Abbreviation for Persian month: Esfand', 'Esf'), ); } diff --git a/app/Date/JewishDate.php b/app/Date/JewishDate.php index a20c7dcff3..5ddceb6887 100644 --- a/app/Date/JewishDate.php +++ b/app/Date/JewishDate.php @@ -87,20 +87,20 @@ class JewishDate extends CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('NOMINATIVE', 'Tishrei'), - 2 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('NOMINATIVE', 'Heshvan'), - 3 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('NOMINATIVE', 'Kislev'), - 4 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('NOMINATIVE', 'Tevet'), - 5 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('NOMINATIVE', 'Shevat'), - 6 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('NOMINATIVE', 'Adar I'), - 7 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('NOMINATIVE', 'Adar'), - -7 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('NOMINATIVE', 'Adar II'), - 8 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('NOMINATIVE', 'Nissan'), - 9 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('NOMINATIVE', 'Iyar'), - 10 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('NOMINATIVE', 'Sivan'), - 11 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('NOMINATIVE', 'Tamuz'), - 12 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('NOMINATIVE', 'Av'), - 13 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('NOMINATIVE', 'Elul'), + 1 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('NOMINATIVE', 'Tishrei'), + 2 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('NOMINATIVE', 'Heshvan'), + 3 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('NOMINATIVE', 'Kislev'), + 4 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('NOMINATIVE', 'Tevet'), + 5 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('NOMINATIVE', 'Shevat'), + 6 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('NOMINATIVE', 'Adar I'), + 7 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('NOMINATIVE', 'Adar'), + -7 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('NOMINATIVE', 'Adar II'), + 8 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('NOMINATIVE', 'Nissan'), + 9 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('NOMINATIVE', 'Iyar'), + 10 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('NOMINATIVE', 'Sivan'), + 11 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('NOMINATIVE', 'Tamuz'), + 12 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('NOMINATIVE', 'Av'), + 13 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('NOMINATIVE', 'Elul'), ); } @@ -118,20 +118,20 @@ class JewishDate extends CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('GENITIVE', 'Tishrei'), - 2 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('GENITIVE', 'Heshvan'), - 3 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('GENITIVE', 'Kislev'), - 4 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('GENITIVE', 'Tevet'), - 5 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('GENITIVE', 'Shevat'), - 6 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('GENITIVE', 'Adar I'), - 7 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('GENITIVE', 'Adar'), - -7 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('GENITIVE', 'Adar II'), - 8 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('GENITIVE', 'Nissan'), - 9 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('GENITIVE', 'Iyar'), - 10 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('GENITIVE', 'Sivan'), - 11 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('GENITIVE', 'Tamuz'), - 12 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('GENITIVE', 'Av'), - 13 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('GENITIVE', 'Elul'), + 1 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('GENITIVE', 'Tishrei'), + 2 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('GENITIVE', 'Heshvan'), + 3 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('GENITIVE', 'Kislev'), + 4 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('GENITIVE', 'Tevet'), + 5 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('GENITIVE', 'Shevat'), + 6 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('GENITIVE', 'Adar I'), + 7 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('GENITIVE', 'Adar'), + -7 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('GENITIVE', 'Adar II'), + 8 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('GENITIVE', 'Nissan'), + 9 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('GENITIVE', 'Iyar'), + 10 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('GENITIVE', 'Sivan'), + 11 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('GENITIVE', 'Tamuz'), + 12 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('GENITIVE', 'Av'), + 13 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('GENITIVE', 'Elul'), ); } @@ -149,20 +149,20 @@ class JewishDate extends CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('LOCATIVE', 'Tishrei'), - 2 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('LOCATIVE', 'Heshvan'), - 3 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('LOCATIVE', 'Kislev'), - 4 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('LOCATIVE', 'Tevet'), - 5 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('LOCATIVE', 'Shevat'), - 6 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('LOCATIVE', 'Adar I'), - 7 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('LOCATIVE', 'Adar'), - -7 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('LOCATIVE', 'Adar II'), - 8 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('LOCATIVE', 'Nissan'), - 9 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('LOCATIVE', 'Iyar'), - 10 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('LOCATIVE', 'Sivan'), - 11 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('LOCATIVE', 'Tamuz'), - 12 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('LOCATIVE', 'Av'), - 13 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('LOCATIVE', 'Elul'), + 1 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('LOCATIVE', 'Tishrei'), + 2 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('LOCATIVE', 'Heshvan'), + 3 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('LOCATIVE', 'Kislev'), + 4 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('LOCATIVE', 'Tevet'), + 5 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('LOCATIVE', 'Shevat'), + 6 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('LOCATIVE', 'Adar I'), + 7 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('LOCATIVE', 'Adar'), + -7 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('LOCATIVE', 'Adar II'), + 8 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('LOCATIVE', 'Nissan'), + 9 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('LOCATIVE', 'Iyar'), + 10 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('LOCATIVE', 'Sivan'), + 11 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('LOCATIVE', 'Tamuz'), + 12 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('LOCATIVE', 'Av'), + 13 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('LOCATIVE', 'Elul'), ); } @@ -180,20 +180,20 @@ class JewishDate extends CalendarDate { if ($translated_month_names === null) { $translated_month_names = array( 0 => '', - 1 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('INSTRUMENTAL', 'Tishrei'), - 2 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('INSTRUMENTAL', 'Heshvan'), - 3 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('INSTRUMENTAL', 'Kislev'), - 4 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('INSTRUMENTAL', 'Tevet'), - 5 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('INSTRUMENTAL', 'Shevat'), - 6 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('INSTRUMENTAL', 'Adar I'), - 7 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('INSTRUMENTAL', 'Adar'), - -7 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('INSTRUMENTAL', 'Adar II'), - 8 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('INSTRUMENTAL', 'Nissan'), - 9 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('INSTRUMENTAL', 'Iyar'), - 10 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('INSTRUMENTAL', 'Sivan'), - 11 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('INSTRUMENTAL', 'Tamuz'), - 12 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('INSTRUMENTAL', 'Av'), - 13 => /* I18N: a month in the Jewish calendar */ I18N::translate_c('INSTRUMENTAL', 'Elul'), + 1 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('INSTRUMENTAL', 'Tishrei'), + 2 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('INSTRUMENTAL', 'Heshvan'), + 3 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('INSTRUMENTAL', 'Kislev'), + 4 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('INSTRUMENTAL', 'Tevet'), + 5 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('INSTRUMENTAL', 'Shevat'), + 6 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('INSTRUMENTAL', 'Adar I'), + 7 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('INSTRUMENTAL', 'Adar'), + -7 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('INSTRUMENTAL', 'Adar II'), + 8 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('INSTRUMENTAL', 'Nissan'), + 9 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('INSTRUMENTAL', 'Iyar'), + 10 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('INSTRUMENTAL', 'Sivan'), + 11 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('INSTRUMENTAL', 'Tamuz'), + 12 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('INSTRUMENTAL', 'Av'), + 13 => /* I18N: a month in the Jewish calendar */ I18N::translateContext('INSTRUMENTAL', 'Elul'), ); } diff --git a/app/Fact.php b/app/Fact.php index 63ae62c1bc..6be581e2b4 100644 --- a/app/Fact.php +++ b/app/Fact.php @@ -265,7 +265,7 @@ class Fact { } // no break - drop into next case default: - return WT_Gedcom_Tag::getLabel($this->tag, $this->parent); + return GedcomTag::getLabel($this->tag, $this->parent); } } @@ -390,7 +390,7 @@ class Fact { $attributes[] = $place; } } - $html = WT_Gedcom_Tag::getLabelValue($this->getTag(), implode(' — ', $attributes), $this->getParent()); + $html = GedcomTag::getLabelValue($this->getTag(), implode(' — ', $attributes), $this->getParent()); if ($this->isPendingAddition()) { return '<div class="new">' . $html . '</div>'; } elseif ($this->isPendingDeletion()) { diff --git a/app/Gedcom/Code/Adop.php b/app/Gedcom/GedcomCodeAdop.php index 3560de8a17..c430a4d1c5 100644 --- a/app/Gedcom/Code/Adop.php +++ b/app/Gedcom/GedcomCodeAdop.php @@ -17,9 +17,9 @@ namespace Fisharebest\Webtrees; */ /** - * Class WT_Gedcom_Code_Adop - Functions and logic for GEDCOM "PEDI" codes + * Class GedcomCodeAdop - Functions and logic for GEDCOM "PEDI" codes */ -class WT_Gedcom_Code_Adop { +class GedcomCodeAdop { /** @var string[] A list of possible adoption codes */ private static $TYPES = array('BOTH', 'HUSB', 'WIFE'); @@ -42,27 +42,27 @@ class WT_Gedcom_Code_Adop { case 'BOTH': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Adopted by both parents'); + return I18N::translateContext('MALE', 'Adopted by both parents'); case 'F': - return I18N::translate_c('FEMALE', 'Adopted by both parents'); + return I18N::translateContext('FEMALE', 'Adopted by both parents'); default: return I18N::translate('Adopted by both parents'); } case 'HUSB': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Adopted by father'); + return I18N::translateContext('MALE', 'Adopted by father'); case 'F': - return I18N::translate_c('FEMALE', 'Adopted by father'); + return I18N::translateContext('FEMALE', 'Adopted by father'); default: return I18N::translate('Adopted by father'); } case 'WIFE': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Adopted by mother'); + return I18N::translateContext('MALE', 'Adopted by mother'); case 'F': - return I18N::translate_c('FEMALE', 'Adopted by mother'); + return I18N::translateContext('FEMALE', 'Adopted by mother'); default: return I18N::translate('Adopted by mother'); } diff --git a/app/Gedcom/Code/Name.php b/app/Gedcom/GedcomCodeName.php index a03fc99fa0..1703e79c0c 100644 --- a/app/Gedcom/Code/Name.php +++ b/app/Gedcom/GedcomCodeName.php @@ -17,9 +17,9 @@ namespace Fisharebest\Webtrees; */ /** - * Class WT_Gedcom_Code_Name - Functions and logic for GEDCOM "NAME" codes + * Class GedcomCodeName - Functions and logic for GEDCOM "NAME" codes */ -class WT_Gedcom_Code_Name { +class GedcomCodeName { /** @var string[] A list of possible types of name */ private static $TYPES = array('adopted', 'aka', 'birth', 'change', 'estate', 'immigrant', 'maiden', 'married', 'religious'); @@ -43,10 +43,10 @@ class WT_Gedcom_Code_Name { switch ($sex) { case 'M': /* I18N: The name given to a child by its adoptive parents */ - return I18N::translate_c('MALE', 'adopted name'); + return I18N::translateContext('MALE', 'adopted name'); case 'F': /* I18N: The name given to a child by its adoptive parents */ - return I18N::translate_c('FEMALE', 'adopted name'); + return I18N::translateContext('FEMALE', 'adopted name'); default: /* I18N: The name given to a child by its adoptive parents */ return I18N::translate('adopted name'); @@ -55,10 +55,10 @@ class WT_Gedcom_Code_Name { switch ($sex) { case 'M': /* I18N: The name by which an individual is also known. e.g. a professional name or a stage name */ - return I18N::translate_c('MALE', 'also known as'); + return I18N::translateContext('MALE', 'also known as'); case 'F': /* I18N: The name by which an individual is also known. e.g. a professional name or a stage name */ - return I18N::translate_c('FEMALE', 'also known as'); + return I18N::translateContext('FEMALE', 'also known as'); default: /* I18N: The name by which an individual is also known. e.g. a professional name or a stage name */ return I18N::translate('also known as'); @@ -67,10 +67,10 @@ class WT_Gedcom_Code_Name { switch ($sex) { case 'M': /* I18N: The name given to an individual at their birth */ - return I18N::translate_c('MALE', 'birth name'); + return I18N::translateContext('MALE', 'birth name'); case 'F': /* I18N: The name given to an individual at their birth */ - return I18N::translate_c('FEMALE', 'birth name'); + return I18N::translateContext('FEMALE', 'birth name'); default: /* I18N: The name given to an individual at their birth */ return I18N::translate('birth name'); @@ -79,10 +79,10 @@ class WT_Gedcom_Code_Name { switch ($sex) { case 'M': /* I18N: A name chosen by an individual, to replace their existing name (whether legal or otherwise) */ - return I18N::translate_c('MALE', 'change of name'); + return I18N::translateContext('MALE', 'change of name'); case 'F': /* I18N: A name chosen by an individual, to replace their existing name (whether legal or otherwise) */ - return I18N::translate_c('FEMALE', 'change of name'); + return I18N::translateContext('FEMALE', 'change of name'); default: /* I18N: A name chosen by an individual, to replace their existing name (whether legal or otherwise) */ return I18N::translate('change of name'); @@ -91,10 +91,10 @@ class WT_Gedcom_Code_Name { switch ($sex) { case 'M': /* I18N: A name given to an individual, from the farm or estate on which they lived or worked */ - return I18N::translate_c('MALE', 'estate name'); + return I18N::translateContext('MALE', 'estate name'); case 'F': /* I18N: A name given to an individual, from the farm or estate on which they lived or worked */ - return I18N::translate_c('FEMALE', 'estate name'); + return I18N::translateContext('FEMALE', 'estate name'); default: /* I18N: A name given to an individual, from the farm or estate on which they lived or worked */ return I18N::translate('estate name'); @@ -103,10 +103,10 @@ class WT_Gedcom_Code_Name { switch ($sex) { case 'M': /* I18N: A name taken on immigration - e.g. migrants to the USA frequently anglicized their names */ - return I18N::translate_c('MALE', 'immigration name'); + return I18N::translateContext('MALE', 'immigration name'); case 'F': /* I18N: A name taken on immigration - e.g. migrants to the USA frequently anglicized their names */ - return I18N::translate_c('FEMALE', 'immigration name'); + return I18N::translateContext('FEMALE', 'immigration name'); default: /* I18N: A name taken on immigration - e.g. migrants to the USA frequently anglicized their names */ return I18N::translate('immigration name'); @@ -120,10 +120,10 @@ class WT_Gedcom_Code_Name { switch ($sex) { case 'M': /* I18N: A name taken on marriage - usually the wife takes the husband’s surname */ - return I18N::translate_c('MALE', 'married name'); + return I18N::translateContext('MALE', 'married name'); case 'F': /* I18N: A name taken on marriage - usually the wife takes the husband’s surname */ - return I18N::translate_c('FEMALE', 'married name'); + return I18N::translateContext('FEMALE', 'married name'); default: /* I18N: A name taken on marriage - usually the wife takes the husband’s surname */ return I18N::translate('married name'); @@ -132,10 +132,10 @@ class WT_Gedcom_Code_Name { switch ($sex) { case 'M': /* I18N: A name taken when entering a religion or a religious order */ - return I18N::translate_c('MALE', 'religious name'); + return I18N::translateContext('MALE', 'religious name'); case 'F': /* I18N: A name taken when entering a religion or a religious order */ - return I18N::translate_c('FEMALE', 'religious name'); + return I18N::translateContext('FEMALE', 'religious name'); default: /* I18N: A name taken when entering a religion or a religious order */ return I18N::translate('religious name'); diff --git a/app/Gedcom/Code/Pedi.php b/app/Gedcom/GedcomCodePedi.php index dd62f9dd76..f5ba8718e8 100644 --- a/app/Gedcom/Code/Pedi.php +++ b/app/Gedcom/GedcomCodePedi.php @@ -17,9 +17,9 @@ namespace Fisharebest\Webtrees; */ /** - * Class WT_Gedcom_Code_Pedi - Functions and logic for GEDCOM "PEDI" codes + * Class GedcomCodePedi - Functions and logic for GEDCOM "PEDI" codes */ -class WT_Gedcom_Code_Pedi { +class GedcomCodePedi { /** @var string[] Possible values for pedigree field */ private static $TYPES = array('adopted', 'birth', 'foster', 'rada', 'sealing'); @@ -42,44 +42,44 @@ class WT_Gedcom_Code_Pedi { case 'birth': switch ($sex) { case 'M': - return I18N::translate_c('Male pedigree', 'Birth'); + return I18N::translateContext('Male pedigree', 'Birth'); case 'F': - return I18N::translate_c('Female pedigree', 'Birth'); + return I18N::translateContext('Female pedigree', 'Birth'); default: - return I18N::translate_c('Pedigree', 'Birth'); + return I18N::translateContext('Pedigree', 'Birth'); } case 'adopted': switch ($sex) { case 'M': - return I18N::translate_c('Male pedigree', 'Adopted'); + return I18N::translateContext('Male pedigree', 'Adopted'); case 'F': - return I18N::translate_c('Female pedigree', 'Adopted'); + return I18N::translateContext('Female pedigree', 'Adopted'); default: - return I18N::translate_c('Pedigree', 'Adopted'); + return I18N::translateContext('Pedigree', 'Adopted'); } case 'foster': switch ($sex) { case 'M': - return I18N::translate_c('Male pedigree', 'Foster'); + return I18N::translateContext('Male pedigree', 'Foster'); case 'F': - return I18N::translate_c('Female pedigree', 'Foster'); + return I18N::translateContext('Female pedigree', 'Foster'); default: - return I18N::translate_c('Pedigree', 'Foster'); + return I18N::translateContext('Pedigree', 'Foster'); } case 'sealing': switch ($sex) { case 'M': return /* I18N: “sealing” is a ceremony in the Mormon church. */ - I18N::translate_c('Male pedigree', 'Sealing'); + I18N::translateContext('Male pedigree', 'Sealing'); case 'F': return /* I18N: “sealing” is a ceremony in the Mormon church. */ - I18N::translate_c('Female pedigree', 'Sealing'); + I18N::translateContext('Female pedigree', 'Sealing'); default: return /* I18N: “sealing” is a ceremony in the Mormon church. */ - I18N::translate_c('Pedigree', 'Sealing'); + I18N::translateContext('Pedigree', 'Sealing'); } case 'rada': // Not standard GEDCOM - a webtrees extension diff --git a/app/Gedcom/Code/Quay.php b/app/Gedcom/GedcomCodeQuay.php index c2db68573d..336bc2a53e 100644 --- a/app/Gedcom/Code/Quay.php +++ b/app/Gedcom/GedcomCodeQuay.php @@ -17,9 +17,9 @@ namespace Fisharebest\Webtrees; */ /** - * Class WT_Gedcom_Code_Quay - Functions and logic for GEDCOM "QUAY" codes + * Class GedcomCodeQuay - Functions and logic for GEDCOM "QUAY" codes */ -class WT_Gedcom_Code_Quay { +class GedcomCodeQuay { private static $TYPES = array('3', '2', '1', '0'); /** diff --git a/app/Gedcom/Code/Rela.php b/app/Gedcom/GedcomCodeRela.php index 73199638c7..3ad0993caf 100644 --- a/app/Gedcom/Code/Rela.php +++ b/app/Gedcom/GedcomCodeRela.php @@ -17,9 +17,9 @@ namespace Fisharebest\Webtrees; */ /** - * Class WT_Gedcom_Code_Rela - Functions and logic for GEDCOM "RELA" codes + * Class GedcomCodeRela - Functions and logic for GEDCOM "RELA" codes */ -class WT_Gedcom_Code_Rela { +class GedcomCodeRela { /** @var string[] List of possible values for the RELA tag */ private static $TYPES = array( @@ -53,18 +53,18 @@ class WT_Gedcom_Code_Rela { case 'attendant': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Attendant'); + return I18N::translateContext('MALE', 'Attendant'); case 'F': - return I18N::translate_c('FEMALE', 'Attendant'); + return I18N::translateContext('FEMALE', 'Attendant'); default: return I18N::translate('Attendant'); } case 'attending': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Attending'); + return I18N::translateContext('MALE', 'Attending'); case 'F': - return I18N::translate_c('FEMALE', 'Attending'); + return I18N::translateContext('FEMALE', 'Attending'); default: return I18N::translate('Attending'); } @@ -77,9 +77,9 @@ class WT_Gedcom_Code_Rela { case 'buyer': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Buyer'); + return I18N::translateContext('MALE', 'Buyer'); case 'F': - return I18N::translate_c('FEMALE', 'Buyer'); + return I18N::translateContext('FEMALE', 'Buyer'); default: return I18N::translate('Buyer'); } @@ -89,27 +89,27 @@ class WT_Gedcom_Code_Rela { case 'civil_registrar': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Civil registrar'); + return I18N::translateContext('MALE', 'Civil registrar'); case 'F': - return I18N::translate_c('FEMALE', 'Civil registrar'); + return I18N::translateContext('FEMALE', 'Civil registrar'); default: return I18N::translate('Civil registrar'); } case 'employee': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Employee'); + return I18N::translateContext('MALE', 'Employee'); case 'F': - return I18N::translate_c('FEMALE', 'Employee'); + return I18N::translateContext('FEMALE', 'Employee'); default: return I18N::translate('Employee'); } case 'employer': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Employer'); + return I18N::translateContext('MALE', 'Employer'); case 'F': - return I18N::translate_c('FEMALE', 'Employer'); + return I18N::translateContext('FEMALE', 'Employer'); default: return I18N::translate('Employer'); } @@ -125,9 +125,9 @@ class WT_Gedcom_Code_Rela { case 'friend': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Friend'); + return I18N::translateContext('MALE', 'Friend'); case 'F': - return I18N::translate_c('FEMALE', 'Friend'); + return I18N::translateContext('FEMALE', 'Friend'); default: return I18N::translate('Friend'); } @@ -152,27 +152,27 @@ class WT_Gedcom_Code_Rela { case 'guardian': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Guardian'); + return I18N::translateContext('MALE', 'Guardian'); case 'F': - return I18N::translate_c('FEMALE', 'Guardian'); + return I18N::translateContext('FEMALE', 'Guardian'); default: return I18N::translate('Guardian'); } case 'informant': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Informant'); + return I18N::translateContext('MALE', 'Informant'); case 'F': - return I18N::translate_c('FEMALE', 'Informant'); + return I18N::translateContext('FEMALE', 'Informant'); default: return I18N::translate('Informant'); } case 'lodger': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Lodger'); + return I18N::translateContext('MALE', 'Lodger'); case 'F': - return I18N::translate_c('FEMALE', 'Lodger'); + return I18N::translateContext('FEMALE', 'Lodger'); default: return I18N::translate('Lodger'); } @@ -182,18 +182,18 @@ class WT_Gedcom_Code_Rela { case 'nurse': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Nurse'); + return I18N::translateContext('MALE', 'Nurse'); case 'F': - return I18N::translate_c('FEMALE', 'Nurse'); + return I18N::translateContext('FEMALE', 'Nurse'); default: return I18N::translate('Nurse'); } case 'owner': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Owner'); + return I18N::translateContext('MALE', 'Owner'); case 'F': - return I18N::translate_c('FEMALE', 'Owner'); + return I18N::translateContext('FEMALE', 'Owner'); default: return I18N::translate('Owner'); } @@ -206,45 +206,45 @@ class WT_Gedcom_Code_Rela { case 'registry_officer': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Registry officer'); + return I18N::translateContext('MALE', 'Registry officer'); case 'F': - return I18N::translate_c('FEMALE', 'Registry officer'); + return I18N::translateContext('FEMALE', 'Registry officer'); default: return I18N::translate('Registry officer'); } case 'seller': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Seller'); + return I18N::translateContext('MALE', 'Seller'); case 'F': - return I18N::translate_c('FEMALE', 'Seller'); + return I18N::translateContext('FEMALE', 'Seller'); default: return I18N::translate('Seller'); } case 'servant': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Servant'); + return I18N::translateContext('MALE', 'Servant'); case 'F': - return I18N::translate_c('FEMALE', 'Servant'); + return I18N::translateContext('FEMALE', 'Servant'); default: return I18N::translate('Servant'); } case 'slave': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Slave'); + return I18N::translateContext('MALE', 'Slave'); case 'F': - return I18N::translate_c('FEMALE', 'Slave'); + return I18N::translateContext('FEMALE', 'Slave'); default: return I18N::translate('Slave'); } case 'ward': switch ($sex) { case 'M': - return I18N::translate_c('MALE', 'Ward'); + return I18N::translateContext('MALE', 'Ward'); case 'F': - return I18N::translate_c('FEMALE', 'Ward'); + return I18N::translateContext('FEMALE', 'Ward'); default: return I18N::translate('Ward'); } diff --git a/app/Gedcom/Code/Stat.php b/app/Gedcom/GedcomCodeStat.php index d526ef29bc..7cc06bfdba 100644 --- a/app/Gedcom/Code/Stat.php +++ b/app/Gedcom/GedcomCodeStat.php @@ -17,9 +17,9 @@ namespace Fisharebest\Webtrees; */ /** - * Class WT_Gedcom_Code_Stat - Functions and logic for GEDCOM "STAT" codes + * Class GedcomCodeStat - Functions and logic for GEDCOM "STAT" codes */ -class WT_Gedcom_Code_Stat { +class GedcomCodeStat { /** * Get a list of status codes that can be used on a given LDS tag * @@ -43,7 +43,7 @@ class WT_Gedcom_Code_Stat { // LDS_SPOUSE_SEALING_DATE_STATUS return array('CANCELED', 'COMPLETED', 'DNS', 'DNS/CAN', 'EXCLUDED', 'PRE-1970', 'SUBMITTED', 'UNCLEARED'); default: - throw new \InvalidArgumentException('Internal error - bad argument to WT_Gedcom_Code_Stat::statusCodes("' . $tag . '")'); + throw new \InvalidArgumentException('Internal error - bad argument to GedcomCodeStat::statusCodes("' . $tag . '")'); } } diff --git a/app/Gedcom/Code/Temp.php b/app/Gedcom/GedcomCodeTemp.php index be0c4ca8f6..ac24b7b890 100644 --- a/app/Gedcom/Code/Temp.php +++ b/app/Gedcom/GedcomCodeTemp.php @@ -17,9 +17,9 @@ namespace Fisharebest\Webtrees; */ /** - * Class WT_Gedcom_Code_Temp - Functions and logic for GEDCOM "TEMP" codes + * Class GedcomCodeTemp - Functions and logic for GEDCOM "TEMP" codes */ -class WT_Gedcom_Code_Temp { +class GedcomCodeTemp { /** * A list of GEDCOM tags that require a TEMP subtag * diff --git a/app/Gedcom/Tag.php b/app/Gedcom/GedcomTag.php index 6da4dbdaa8..6b101981d5 100644 --- a/app/Gedcom/Tag.php +++ b/app/Gedcom/GedcomTag.php @@ -19,9 +19,9 @@ namespace Fisharebest\Webtrees; use Rhumsaa\Uuid\Uuid; /** - * Class WT_Gedcom_Tag - Static GEDCOM data for Tags + * Class GedcomTag - Static GEDCOM data for Tags */ -class WT_Gedcom_Tag { +class GedcomTag { /** @var string[] All tags that webtrees knows how to translate - including special/internal tags */ private static $ALL_TAGS = array( 'ABBR', 'ADDR', 'ADR1', 'ADR2', 'ADOP', 'ADOP:DATE', 'ADOP:PLAC', @@ -595,7 +595,7 @@ class WT_Gedcom_Tag { if ($record instanceof Repository) { return /* I18N: gedcom tag REPO:NAME */ - I18N::translate_c('Repository', 'Name'); + I18N::translateContext('Repository', 'Name'); } else { return /* I18N: gedcom tag NAME */ @@ -884,18 +884,18 @@ class WT_Gedcom_Tag { case '_ADOP_GCH1': switch ($sex) { case 'M': - return I18N::translate_c('daughter’s son', 'Adoption of a grandson'); + return I18N::translateContext('daughter’s son', 'Adoption of a grandson'); case 'F': - return I18N::translate_c('daughter’s daughter', 'Adoption of a granddaughter'); + return I18N::translateContext('daughter’s daughter', 'Adoption of a granddaughter'); default: return I18N::translate('Adoption of a grandchild'); } case '_ADOP_GCH2': switch ($sex) { case 'M': - return I18N::translate_c('son’s son', 'Adoption of a grandson'); + return I18N::translateContext('son’s son', 'Adoption of a grandson'); case 'F': - return I18N::translate_c('son’s daughter', 'Adoption of a granddaughter'); + return I18N::translateContext('son’s daughter', 'Adoption of a granddaughter'); default: return I18N::translate('Adoption of a grandchild'); } @@ -922,11 +922,11 @@ class WT_Gedcom_Tag { case 'M': return /* I18N: gedcom tag _ADPF */ - I18N::translate_c('MALE', 'Adopted by father'); + I18N::translateContext('MALE', 'Adopted by father'); case 'F': return /* I18N: gedcom tag _ADPF */ - I18N::translate_c('FEMALE', 'Adopted by father'); + I18N::translateContext('FEMALE', 'Adopted by father'); default: return /* I18N: gedcom tag _ADPF */ @@ -937,11 +937,11 @@ class WT_Gedcom_Tag { case 'M': return /* I18N: gedcom tag _ADPM */ - I18N::translate_c('MALE', 'Adopted by mother'); + I18N::translateContext('MALE', 'Adopted by mother'); case 'F': return /* I18N: gedcom tag _ADPM */ - I18N::translate_c('FEMALE', 'Adopted by mother'); + I18N::translateContext('FEMALE', 'Adopted by mother'); default: return /* I18N: gedcom tag _ADPM */ @@ -953,11 +953,11 @@ class WT_Gedcom_Tag { case 'M': return /* I18N: gedcom tag _AKA */ - I18N::translate_c('MALE', 'Also known as'); + I18N::translateContext('MALE', 'Also known as'); case 'F': return /* I18N: gedcom tag _AKA */ - I18N::translate_c('FEMALE', 'Also known as'); + I18N::translateContext('FEMALE', 'Also known as'); default: return /* I18N: gedcom tag _AKA */ @@ -988,18 +988,18 @@ class WT_Gedcom_Tag { case '_BAPM_GCH1': switch ($sex) { case 'M': - return I18N::translate_c('daughter’s son', 'Baptism of a grandson'); + return I18N::translateContext('daughter’s son', 'Baptism of a grandson'); case 'F': - return I18N::translate_c('daughter’s daughter', 'Baptism of a granddaughter'); + return I18N::translateContext('daughter’s daughter', 'Baptism of a granddaughter'); default: return I18N::translate('Baptism of a grandchild'); } case '_BAPM_GCH2': switch ($sex) { case 'M': - return I18N::translate_c('son’s son', 'Baptism of a grandson'); + return I18N::translateContext('son’s son', 'Baptism of a grandson'); case 'F': - return I18N::translate_c('son’s daughter', 'Baptism of a granddaughter'); + return I18N::translateContext('son’s daughter', 'Baptism of a granddaughter'); default: return I18N::translate('Baptism of a grandchild'); } @@ -1046,18 +1046,18 @@ class WT_Gedcom_Tag { case '_BIRT_GCH1': switch ($sex) { case 'M': - return I18N::translate_c('daughter’s son', 'Birth of a grandson'); + return I18N::translateContext('daughter’s son', 'Birth of a grandson'); case 'F': - return I18N::translate_c('daughter’s daughter', 'Birth of a granddaughter'); + return I18N::translateContext('daughter’s daughter', 'Birth of a granddaughter'); default: return I18N::translate('Birth of a grandchild'); } case '_BIRT_GCH2': switch ($sex) { case 'M': - return I18N::translate_c('son’s son', 'Birth of a grandson'); + return I18N::translateContext('son’s son', 'Birth of a grandson'); case 'F': - return I18N::translate_c('son’s daughter', 'Birth of a granddaughter'); + return I18N::translateContext('son’s daughter', 'Birth of a granddaughter'); default: return I18N::translate('Birth of a grandchild'); } @@ -1108,18 +1108,18 @@ class WT_Gedcom_Tag { case '_BURI_GCH1': switch ($sex) { case 'M': - return I18N::translate_c('daughter’s son', 'Burial of a grandson'); + return I18N::translateContext('daughter’s son', 'Burial of a grandson'); case 'F': - return I18N::translate_c('daughter’s daughter', 'Burial of a granddaughter'); + return I18N::translateContext('daughter’s daughter', 'Burial of a granddaughter'); default: return I18N::translate('Burial of a grandchild'); } case '_BURI_GCH2': switch ($sex) { case 'M': - return I18N::translate_c('son’s son', 'Burial of a grandson'); + return I18N::translateContext('son’s son', 'Burial of a grandson'); case 'F': - return I18N::translate_c('son’s daughter', 'Burial of a granddaughter'); + return I18N::translateContext('son’s daughter', 'Burial of a granddaughter'); default: return I18N::translate('Burial of a grandchild'); } @@ -1207,18 +1207,18 @@ class WT_Gedcom_Tag { case '_CHR_GCH1': switch ($sex) { case 'M': - return I18N::translate_c('daughter’s son', 'Christening of a grandson'); + return I18N::translateContext('daughter’s son', 'Christening of a grandson'); case 'F': - return I18N::translate_c('daughter’s daughter', 'Christening of a granddaughter'); + return I18N::translateContext('daughter’s daughter', 'Christening of a granddaughter'); default: return I18N::translate('Christening of a grandchild'); } case '_CHR_GCH2': switch ($sex) { case 'M': - return I18N::translate_c('son’s son', 'Christening of a grandson'); + return I18N::translateContext('son’s son', 'Christening of a grandson'); case 'F': - return I18N::translate_c('son’s daughter', 'Christening of a granddaughter'); + return I18N::translateContext('son’s daughter', 'Christening of a granddaughter'); default: return I18N::translate('Christening of a grandchild'); } @@ -1265,18 +1265,18 @@ class WT_Gedcom_Tag { case '_CREM_GCH1': switch ($sex) { case 'M': - return I18N::translate_c('daughter’s son', 'Cremation of a grandson'); + return I18N::translateContext('daughter’s son', 'Cremation of a grandson'); case 'F': - return I18N::translate_c('daughter’s daughter', 'Cremation of a granddaughter'); + return I18N::translateContext('daughter’s daughter', 'Cremation of a granddaughter'); default: return I18N::translate('Cremation of a grandchild'); } case '_CREM_GCH2': switch ($sex) { case 'M': - return I18N::translate_c('son’s son', 'Cremation of a grandson'); + return I18N::translateContext('son’s son', 'Cremation of a grandson'); case 'F': - return I18N::translate_c('son’s daughter', 'Cremation of a granddaughter'); + return I18N::translateContext('son’s daughter', 'Cremation of a granddaughter'); default: return I18N::translate('Cremation of a grandchild'); } @@ -1368,18 +1368,18 @@ class WT_Gedcom_Tag { case '_DEAT_GCH1': switch ($sex) { case 'M': - return I18N::translate_c('daughter’s son', 'Death of a grandson'); + return I18N::translateContext('daughter’s son', 'Death of a grandson'); case 'F': - return I18N::translate_c('daughter’s daughter', 'Death of a granddaughter'); + return I18N::translateContext('daughter’s daughter', 'Death of a granddaughter'); default: return I18N::translate('Death of a grandchild'); } case '_DEAT_GCH2': switch ($sex) { case 'M': - return I18N::translate_c('son’s son', 'Death of a grandson'); + return I18N::translateContext('son’s son', 'Death of a grandson'); case 'F': - return I18N::translate_c('son’s daughter', 'Death of a granddaughter'); + return I18N::translateContext('son’s daughter', 'Death of a granddaughter'); default: return I18N::translate('Death of a grandchild'); } @@ -1533,11 +1533,11 @@ class WT_Gedcom_Tag { case 'M': return /* I18N: gedcom tag _INTE */ - I18N::translate_c('MALE', 'Interred'); + I18N::translateContext('MALE', 'Interred'); case 'F': return /* I18N: gedcom tag _INTE */ - I18N::translate_c('FEMALE', 'Interred'); + I18N::translateContext('FEMALE', 'Interred'); default: return /* I18N: gedcom tag _INTE */ @@ -1586,18 +1586,18 @@ class WT_Gedcom_Tag { case '_MARR_GCH1': switch ($sex) { case 'M': - return I18N::translate_c('daughter’s son', 'Marriage of a grandson'); + return I18N::translateContext('daughter’s son', 'Marriage of a grandson'); case 'F': - return I18N::translate_c('daughter’s daughter', 'Marriage of a granddaughter'); + return I18N::translateContext('daughter’s daughter', 'Marriage of a granddaughter'); default: return I18N::translate('Marriage of a grandchild'); } case '_MARR_GCH2': switch ($sex) { case 'M': - return I18N::translate_c('son’s son', 'Marriage of a grandson'); + return I18N::translateContext('son’s son', 'Marriage of a grandson'); case 'F': - return I18N::translate_c('son’s daughter', 'Marriage of a granddaughter'); + return I18N::translateContext('son’s daughter', 'Marriage of a granddaughter'); default: return I18N::translate('Marriage of a grandchild'); } @@ -1683,11 +1683,11 @@ class WT_Gedcom_Tag { case 'M': return /* I18N: gedcom tag _NMAR */ - I18N::translate_c('MALE', 'Never married'); + I18N::translateContext('MALE', 'Never married'); case 'F': return /* I18N: gedcom tag _NMAR */ - I18N::translate_c('FEMALE', 'Never married'); + I18N::translateContext('FEMALE', 'Never married'); default: return /* I18N: gedcom tag _NMAR */ @@ -1698,11 +1698,11 @@ class WT_Gedcom_Tag { case 'M': return /* I18N: gedcom tag _NMR */ - I18N::translate_c('MALE', 'Not married'); + I18N::translateContext('MALE', 'Not married'); case 'F': return /* I18N: gedcom tag _NMR */ - I18N::translate_c('FEMALE', 'Not married'); + I18N::translateContext('FEMALE', 'Not married'); default: return /* I18N: gedcom tag _NMR */ @@ -1772,9 +1772,9 @@ class WT_Gedcom_Tag { case '__BRTM_GCHI': return I18N::translate('Brit milah of a grandson'); case '__BRTM_GCH1': - return I18N::translate_c('daughter’s son', 'Brit milah of a grandson'); + return I18N::translateContext('daughter’s son', 'Brit milah of a grandson'); case '__BRTM_GCH2': - return I18N::translate_c('son’s son', 'Brit milah of a grandson'); + return I18N::translateContext('son’s son', 'Brit milah of a grandson'); case '__BRTM_HSIB': return I18N::translate('Brit milah of a half-brother'); case '__BRTM_SIBL': diff --git a/app/I18N.php b/app/I18N.php index d10c7d405a..38d93bec30 100644 --- a/app/I18N.php +++ b/app/I18N.php @@ -200,7 +200,7 @@ class I18N { Zend_Locale::setCache(self::$cache); Zend_Translate::setCache(self::$cache); - $installed_languages = self::installed_languages(); + $installed_languages = self::installedLanguages(); if (is_null($locale) || !array_key_exists($locale, $installed_languages)) { // Automatic locale selection. if (array_key_exists(Filter::get('lang'), $installed_languages)) { @@ -320,7 +320,7 @@ class I18N { * * @return array */ - public static function installed_languages() { + public static function installedLanguages() { $mo_files = glob(WT_ROOT . 'language' . DIRECTORY_SEPARATOR . '*.mo'); $cache_key = md5(serialize($mo_files)); @@ -360,7 +360,7 @@ class I18N { * * @return string */ - public static function html_markup() { + public static function htmlAttributes() { list($lang) = preg_split('/[-_@]/', self::$locale); return 'lang="' . $lang . '" dir="' . self::direction() . '"'; } @@ -453,7 +453,7 @@ class I18N { * * @return string */ - public static function translate_c(/* var_args */) { + public static function translateContext(/* var_args */) { $args = func_get_args(); $msgid = $args[0] . "\x04" . $args[1]; $msgtxt = self::$translation_adapter->getAdapter()->_($msgid); @@ -508,7 +508,7 @@ class I18N { * * @return string */ - public static function gedcom_age($string) { + public static function gedcomAge($string) { switch ($string) { case 'STILLBORN': // I18N: Description of an individual’s age at an event. For example, Died 14 Jan 1900 (stillborn) diff --git a/app/Individual.php b/app/Individual.php index a24a0b5bf0..7ec02fb24c 100644 --- a/app/Individual.php +++ b/app/Individual.php @@ -924,10 +924,10 @@ class Individual extends GedcomRecord { function getChildFamilyLabel(Family $family) { if (preg_match('/\n1 FAMC @' . $family->getXref() . '@(?:\n[2-9].*)*\n2 PEDI (.+)/', $this->getGedcom(), $match)) { // A specified pedigree - return WT_Gedcom_Code_Pedi::getChildFamilyLabel($match[1]); + return GedcomCodePedi::getChildFamilyLabel($match[1]); } else { // Default (birth) pedigree - return WT_Gedcom_Code_Pedi::getChildFamilyLabel(''); + return GedcomCodePedi::getChildFamilyLabel(''); } } diff --git a/app/Module/AlbumModule.php b/app/Module/AlbumModule.php index 2b9b474020..691bc36e88 100644 --- a/app/Module/AlbumModule.php +++ b/app/Module/AlbumModule.php @@ -39,13 +39,13 @@ class AlbumModule extends Module implements ModuleTabInterface { /** {@inheritdoc} */ public function hasTabContent() { - return WT_USER_CAN_EDIT || $this->get_media(); + return WT_USER_CAN_EDIT || $this->getMedia(); } /** {@inheritdoc} */ public function isGrayedOut() { - return !$this->get_media(); + return !$this->getMedia(); } /** {@inheritdoc} */ @@ -68,7 +68,7 @@ class AlbumModule extends Module implements ModuleTabInterface { $html .= I18N::translate('Link to an existing media object'); $html .= '</a></span>'; } - if (WT_USER_GEDCOM_ADMIN && $this->get_media()) { + if (WT_USER_GEDCOM_ADMIN && $this->getMedia()) { // Popup Reorder Media $html .= '<span><a href="#" onclick="reorder_media(\'' . $controller->record->getXref() . '\')">'; $html .= '<img src="' . Theme::theme()->assetUrl() . 'images/images.png" id="head_icon" class="icon" title="' . I18N::translate('Re-order media') . '" alt="' . I18N::translate('Re-order media') . '">'; @@ -81,7 +81,7 @@ class AlbumModule extends Module implements ModuleTabInterface { // Used when sorting media on album tab page $html .= '<table class="facts_table"><tr><td class="facts_value">'; // one-cell table - for presentation only $html .= '<ul class="album-list">'; - foreach ($this->get_media() as $media) { + foreach ($this->getMedia() as $media) { //View Edit Menu ---------------------------------- //Get media item Notes @@ -167,7 +167,7 @@ class AlbumModule extends Module implements ModuleTabInterface { * * @return Media[] */ - private function get_media() { + private function getMedia() { global $controller; if ($this->media_list === null) { diff --git a/app/Module/BatchUpdate/BatchUpdateBasePlugin.php b/app/Module/BatchUpdate/BatchUpdateBasePlugin.php index 3d9d034920..4dcecf4c70 100644 --- a/app/Module/BatchUpdate/BatchUpdateBasePlugin.php +++ b/app/Module/BatchUpdate/BatchUpdateBasePlugin.php @@ -88,7 +88,7 @@ class BatchUpdateBasePlugin { $old_lines = preg_split('/[\n]+/', $record->getGedcom()); $new_lines = preg_split('/[\n]+/', $this->updateRecord($record->getXref(), $record->getGedcom())); // Find matching lines using longest-common-subsequence algorithm. - $lcs = self::LongestCommonSubsequence($old_lines, $new_lines, 0, count($old_lines) - 1, 0, count($new_lines) - 1); + $lcs = self::longestCommonSubsequence($old_lines, $new_lines, 0, count($old_lines) - 1, 0, count($new_lines) - 1); $diff_lines = array(); $last_old = -1; @@ -127,22 +127,22 @@ class BatchUpdateBasePlugin { * * @return array */ - private static function LongestCommonSubsequence($X, $Y, $x1, $x2, $y1, $y2) { + private static function longestCommonSubsequence($X, $Y, $x1, $x2, $y1, $y2) { if ($x2 - $x1 >= 0 && $y2 - $y1 >= 0) { if ($X[$x1] == $Y[$y1]) { // Match at start of sequence - $tmp = self::LongestCommonSubsequence($X, $Y, $x1 + 1, $x2, $y1 + 1, $y2); + $tmp = self::longestCommonSubsequence($X, $Y, $x1 + 1, $x2, $y1 + 1, $y2); array_unshift($tmp, array($x1, $y1)); return $tmp; } elseif ($X[$x2] == $Y[$y2]) { // Match at end of sequence - $tmp = self::LongestCommonSubsequence($X, $Y, $x1, $x2 - 1, $y1, $y2 - 1); + $tmp = self::longestCommonSubsequence($X, $Y, $x1, $x2 - 1, $y1, $y2 - 1); array_push($tmp, array($x2, $y2)); return $tmp; } else { // No match. Look for subsequences - $tmp1 = self::LongestCommonSubsequence($X, $Y, $x1, $x2, $y1, $y2 - 1); - $tmp2 = self::LongestCommonSubsequence($X, $Y, $x1, $x2 - 1, $y1, $y2); + $tmp1 = self::longestCommonSubsequence($X, $Y, $x1, $x2, $y1, $y2 - 1); + $tmp2 = self::longestCommonSubsequence($X, $Y, $x1, $x2 - 1, $y1, $y2); return count($tmp1) > count($tmp2) ? $tmp1 : $tmp2; } } else { diff --git a/app/Module/CensusAssistantModule.php b/app/Module/CensusAssistantModule.php index f8c1145474..78b4516e38 100644 --- a/app/Module/CensusAssistantModule.php +++ b/app/Module/CensusAssistantModule.php @@ -38,10 +38,10 @@ class CensusAssistantModule extends Module { require WT_ROOT . WT_MODULES_DIR . $this->getName() . '/_CENS/census_3_find.php'; break; case 'media_3_find': - self::media_3_find(); + self::mediaFind(); break; case 'media_query_3a': - self::media_query_3a(); + self::mediaQuery(); break; default: echo $mod_action; @@ -52,7 +52,7 @@ class CensusAssistantModule extends Module { /** * ... */ - private static function media_3_find() { + private static function mediaFind() { global $WT_TREE; $controller = new SimpleController; @@ -134,7 +134,7 @@ class CensusAssistantModule extends Module { '".$indi->getbirthplace() . "'); return false;\"> <b>".$indi->getFullName() . "</b> "; - $born = WT_Gedcom_Tag::getLabel('BIRT'); + $born = GedcomTag::getLabel('BIRT'); echo "</span><br><span class=\"list_item\">", $born, " ", $indi->getbirthyear(), " ", $indi->getbirthplace(), "</span></a></li>"; echo "<hr>"; } @@ -151,7 +151,7 @@ class CensusAssistantModule extends Module { /** * ... */ - private static function media_query_3a() { + private static function mediaQuery() { $iid2 = Filter::get('iid', WT_REGEX_XREF); $controller = new SimpleController; @@ -306,7 +306,7 @@ class CensusAssistantModule extends Module { * * @return string */ - static function print_addnewnote_assisted_link($element_id, $xref, $action) { + static function addNoteWithAssistantLink($element_id, $xref, $action) { global $controller; // We do not yet support family records diff --git a/app/Module/FamiliesSidebarModule.php b/app/Module/FamiliesSidebarModule.php index 940f8d3b38..a50a7d475e 100644 --- a/app/Module/FamiliesSidebarModule.php +++ b/app/Module/FamiliesSidebarModule.php @@ -78,7 +78,7 @@ class FamiliesModule extends Module implements ModuleSidebarInterface { global $UNKNOWN_NN, $controller; // Fetch a list of the initial letters of all surnames in the database - $initials = WT_Query_Name::surnameAlpha(true, false, WT_GED_ID, false); + $initials = QueryName::surnameAlpha(true, false, WT_GED_ID, false); $controller->addInlineJavascript(' var famloadedNames = new Array(); @@ -164,7 +164,7 @@ class FamiliesModule extends Module implements ModuleSidebarInterface { * @return string */ public function getAlphaSurnames($alpha, $surname1 = '') { - $surnames = WT_Query_Name::surnames('', $alpha, true, true, WT_GED_ID); + $surnames = QueryName::surnames('', $alpha, true, true, WT_GED_ID); $out = '<ul>'; foreach (array_keys($surnames) as $surname) { $out .= '<li id="sb_fam_' . $surname . '" class="sb_fam_surname_li"><a href="' . $surname . '" title="' . $surname . '" alt="' . $alpha . '" class="sb_fam_surname">' . $surname . '</a>'; @@ -188,7 +188,7 @@ class FamiliesModule extends Module implements ModuleSidebarInterface { * @return string */ public function getSurnameFams($alpha, $surname) { - $families = WT_Query_Name::families($surname, $alpha, '', true, WT_GED_ID); + $families = QueryName::families($surname, $alpha, '', true, WT_GED_ID); $out = '<ul>'; foreach ($families as $family) { if ($family->canShowName()) { diff --git a/app/Module/FamilyNavigatorModule.php b/app/Module/FamilyNavigatorModule.php index ffd751f7fc..697c688531 100644 --- a/app/Module/FamilyNavigatorModule.php +++ b/app/Module/FamilyNavigatorModule.php @@ -207,13 +207,13 @@ class FamilyNavigatorModule extends Module implements ModuleSidebarInterface { } if ($stepParents) { $relationship = $father instanceof Individual ? - I18N::translate_c("father’s wife", "step-mother") : I18N::translate_c("mother’s husband", "step-father"); + I18N::translateContext("father’s wife", "step-mother") : I18N::translateContext("mother’s husband", "step-father"); $html .= sprintf(self::TTL, $relationship) . $stepParents; } } } if (!($father instanceof Individual || $mother instanceof Individual)) { - $html .= sprintf(self::MSG, I18N::translate_c('unknown family', 'unknown')); + $html .= sprintf(self::MSG, I18N::translateContext('unknown family', 'unknown')); } return $html; } diff --git a/app/Module/FamilyTreeFavoritesModule.php b/app/Module/FamilyTreeFavoritesModule.php index faaf8457d2..d5ff6d93d0 100644 --- a/app/Module/FamilyTreeFavoritesModule.php +++ b/app/Module/FamilyTreeFavoritesModule.php @@ -182,7 +182,7 @@ class FamilyTreeFavoritesModule extends Module implements ModuleBlockInterface { $content .= '</div>'; $content .= '<div class="add_fav_url">'; $content .= '<input type="radio" name="fav_category" value="url" onclick="jQuery(\'#url, #favtitle\').removeAttr(\'disabled\'); jQuery(\'#gid' . $uniqueID . '\').attr(\'disabled\',\'disabled\').val(\'\');">'; - $content .= '<input type="text" name="url" id="url" size="20" value="" placeholder="' . WT_Gedcom_Tag::getLabel('URL') . '" disabled> '; + $content .= '<input type="text" name="url" id="url" size="20" value="" placeholder="' . GedcomTag::getLabel('URL') . '" disabled> '; $content .= '<input type="text" name="favtitle" id="favtitle" size="20" value="" placeholder="' . I18N::translate('Title') . '" disabled>'; $content .= '<p>' . I18N::translate('Enter an optional note about this favorite') . '</p>'; $content .= '<textarea name="favnote" rows="6" cols="50"></textarea>'; diff --git a/app/Module/FrequentlyAskedQuestionsModule.php b/app/Module/FrequentlyAskedQuestionsModule.php index 90f88f64b7..9e6adcce4d 100644 --- a/app/Module/FrequentlyAskedQuestionsModule.php +++ b/app/Module/FrequentlyAskedQuestionsModule.php @@ -91,7 +91,7 @@ class FrequentlyAskedQuestionsModule extends Module implements ModuleMenuInterfa set_block_setting($block_id, 'header', Filter::post('header')); set_block_setting($block_id, 'faqbody', Filter::post('faqbody')); - $languages = Filter::postArray('lang', null, array_keys(I18N::installed_languages())); + $languages = Filter::postArray('lang', null, array_keys(I18N::installedLanguages())); set_block_setting($block_id, 'languages', implode(',', $languages)); $this->config(); } else { diff --git a/app/Module/GoogleMapsModule.php b/app/Module/GoogleMapsModule.php index 3a6b58af40..e09088c7f9 100644 --- a/app/Module/GoogleMapsModule.php +++ b/app/Module/GoogleMapsModule.php @@ -1653,7 +1653,7 @@ class GoogleMapsModule extends Module implements ModuleConfigInterface, ModuleTa echo '</tr><tr>'; $cols = 0; while ($cols < $max) { - echo '<th>', WT_Gedcom_Tag::getLabel('PLAC'), '</th><th>', I18N::translate('Latitude'), '</th><th>', I18N::translate('Longitude'), '</th>'; + echo '<th>', GedcomTag::getLabel('PLAC'), '</th><th>', I18N::translate('Latitude'), '</th><th>', I18N::translate('Longitude'), '</th>'; $cols++; } echo '</tr>'; @@ -2700,8 +2700,8 @@ class GoogleMapsModule extends Module implements ModuleConfigInterface, ModuleTa <?php $list_latlon = ( - WT_Gedcom_Tag::getLabel('LATI') . "<input name='sv_latiText' id='sv_latiText' type='text' style='width:42px; background:none; border:none;' value='" . $sv_lat . "'>" . - WT_Gedcom_Tag::getLabel('LONG') . "<input name='sv_longText' id='sv_longText' type='text' style='width:42px; background:none; border:none;' value='" . $sv_lng . "'>" . + GedcomTag::getLabel('LATI') . "<input name='sv_latiText' id='sv_latiText' type='text' style='width:42px; background:none; border:none;' value='" . $sv_lat . "'>" . + GedcomTag::getLabel('LONG') . "<input name='sv_longText' id='sv_longText' type='text' style='width:42px; background:none; border:none;' value='" . $sv_lng . "'>" . /* I18N: Compass bearing (in degrees), for street-view mapping */ I18N::translate('Bearing') . "<input name='sv_bearText' id='sv_bearText' type='text' style='width:46px; background:none; border:none;' value='" . $sv_dir . "'>" . /* I18N: Angle of elevation (in degrees), for street-view mapping */ I18N::translate('Elevation') . "<input name='sv_elevText' id='sv_elevText' type='text' style='width:30px; background:none; border:none;' value='" . $sv_pitch . "'>" . I18N::translate('Zoom') . "<input name='sv_zoomText' id='sv_zoomText' type='text' style='width:30px; background:none; border:none;' value='" . $sv_zoom . "'> @@ -3966,7 +3966,7 @@ class GoogleMapsModule extends Module implements ModuleConfigInterface, ModuleTa </td> </tr> <tr> - <td class="descriptionbox"><?php echo WT_Gedcom_Tag::getLabel('PLAC'); ?></td> + <td class="descriptionbox"><?php echo GedcomTag::getLabel('PLAC'); ?></td> <td class="optionbox"><input type="text" id="new_pl_name" name="NEW_PLACE_NAME" value="<?php echo Filter::escapeHtml($place_name); ?>" size="25" class="address_input"> <div id="INDI_PLAC_pop" style="display: inline;"> <?php echo print_specialchar_link('new_pl_name'); ?></div></td><td class="optionbox"> @@ -4017,7 +4017,7 @@ class GoogleMapsModule extends Module implements ModuleConfigInterface, ModuleTa </td> </tr> <tr> - <td class="descriptionbox"><?php echo WT_Gedcom_Tag::getLabel('LATI'); ?></td> + <td class="descriptionbox"><?php echo GedcomTag::getLabel('LATI'); ?></td> <td class="optionbox" colspan="2"> <input type="text" id="NEW_PLACE_LATI" name="NEW_PLACE_LATI" placeholder="<?php echo /* I18N: Measure of latitude/longitude */ I18N::translate('degrees') ?>" value="<?php echo abs($place_lati); ?>" size="20" onchange="updateMap();"> <select name="LATI_CONTROL" onchange="updateMap();"> @@ -4027,7 +4027,7 @@ class GoogleMapsModule extends Module implements ModuleConfigInterface, ModuleTa </td> </tr> <tr> - <td class="descriptionbox"><?php echo WT_Gedcom_Tag::getLabel('LONG'); ?></td> + <td class="descriptionbox"><?php echo GedcomTag::getLabel('LONG'); ?></td> <td class="optionbox" colspan="2"> <input type="text" id="NEW_PLACE_LONG" name="NEW_PLACE_LONG" placeholder="<?php echo I18N::translate('degrees') ?>" value="<?php echo abs($place_long); ?>" size="20" onchange="updateMap();"> <select name="LONG_CONTROL" onchange="updateMap();"> @@ -4548,9 +4548,9 @@ class GoogleMapsModule extends Module implements ModuleConfigInterface, ModuleTa $placelist = $this->getPlaceListLocation($parent, $inactive); echo '<div class="gm_plac_edit">'; echo '<table class="table table-bordered table-condensed table-hover"><tr>'; - echo '<th>', WT_Gedcom_Tag::getLabel('PLAC'), '</th>'; - echo '<th>', WT_Gedcom_Tag::getLabel('LATI'), '</th>'; - echo '<th>', WT_Gedcom_Tag::getLabel('LONG'), '</th>'; + echo '<th>', GedcomTag::getLabel('PLAC'), '</th>'; + echo '<th>', GedcomTag::getLabel('LATI'), '</th>'; + echo '<th>', GedcomTag::getLabel('LONG'), '</th>'; echo '<th>', I18N::translate('Zoom level'), '</th>'; echo '<th>', I18N::translate('Icon'), '</th>'; echo '<th>'; diff --git a/app/Module/HtmlBlockModule.php b/app/Module/HtmlBlockModule.php index 2a94f81c90..82fe3bafe8 100644 --- a/app/Module/HtmlBlockModule.php +++ b/app/Module/HtmlBlockModule.php @@ -123,7 +123,7 @@ class HtmlBlockModule extends Module implements ModuleBlockInterface { set_block_setting($block_id, 'html', Filter::post('html')); set_block_setting($block_id, 'show_timestamp', Filter::postBool('show_timestamp')); set_block_setting($block_id, 'timestamp', Filter::post('timestamp')); - $languages = Filter::postArray('lang', null, array_keys(I18N::installed_languages())); + $languages = Filter::postArray('lang', null, array_keys(I18N::installedLanguages())); set_block_setting($block_id, 'languages', implode(',', $languages)); } @@ -243,7 +243,7 @@ class HtmlBlockModule extends Module implements ModuleBlockInterface { $languages = explode(',', get_block_setting($block_id, 'languages')); echo '<tr><td class="descriptionbox wrap">', - WT_Gedcom_Tag::getLabel('TITL'), + GedcomTag::getLabel('TITL'), '</td><td class="optionbox"><input type="text" name="title" size="30" value="', Filter::escapeHtml($title), '"></td></tr>'; // templates diff --git a/app/Module/IndividualSidebarModule.php b/app/Module/IndividualSidebarModule.php index d5043af1fa..12476f4b4d 100644 --- a/app/Module/IndividualSidebarModule.php +++ b/app/Module/IndividualSidebarModule.php @@ -78,7 +78,7 @@ class IndividualSidebarModule extends Module implements ModuleSidebarInterface { global $WT_IMAGES, $UNKNOWN_NN, $controller; // Fetch a list of the initial letters of all surnames in the database - $initials = WT_Query_Name::surnameAlpha(true, false, WT_GED_ID, false); + $initials = QueryName::surnameAlpha(true, false, WT_GED_ID, false); $controller->addInlineJavascript(' var loadedNames = new Array(); @@ -164,7 +164,7 @@ class IndividualSidebarModule extends Module implements ModuleSidebarInterface { * @return string */ public function getAlphaSurnames($alpha, $surname1 = '') { - $surnames = WT_Query_Name::surnames('', $alpha, true, false, WT_GED_ID); + $surnames = QueryName::surnames('', $alpha, true, false, WT_GED_ID); $out = '<ul>'; foreach (array_keys($surnames) as $surname) { $out .= '<li id="sb_indi_' . $surname . '" class="sb_indi_surname_li"><a href="' . $surname . '" title="' . $surname . '" alt="' . $alpha . '" class="sb_indi_surname">' . $surname . '</a>'; @@ -189,7 +189,7 @@ class IndividualSidebarModule extends Module implements ModuleSidebarInterface { * @return string */ public function getSurnameIndis($alpha, $surname) { - $indis = WT_Query_Name::individuals($surname, $alpha, '', true, false, WT_GED_ID); + $indis = QueryName::individuals($surname, $alpha, '', true, false, WT_GED_ID); $out = '<ul>'; foreach ($indis as $person) { if ($person->canShowName()) { diff --git a/app/Module/MediaTabModule.php b/app/Module/MediaTabModule.php index f156b3de25..2c46034f56 100644 --- a/app/Module/MediaTabModule.php +++ b/app/Module/MediaTabModule.php @@ -70,7 +70,7 @@ class MediaTabModule extends Module implements ModuleTabInterface { ?> <tr> <td class="facts_label"> - <?php echo WT_Gedcom_Tag::getLabel('OBJE'); ?> + <?php echo GedcomTag::getLabel('OBJE'); ?> </td> <td class="facts_value"> <a href="#" onclick="window.open('addmedia.php?action=showmediaform&linktoid=<?php echo $controller->record->getXref(); ?>&ged=<?php echo WT_GEDURL; ?>', '_blank', edit_window_specs); return false;"> diff --git a/app/Module/NotesTabModule.php b/app/Module/NotesTabModule.php index 121b9fd408..5128cecf31 100644 --- a/app/Module/NotesTabModule.php +++ b/app/Module/NotesTabModule.php @@ -80,7 +80,7 @@ class NotesTabModule extends Module implements ModuleTabInterface { ?> <tr> <td class="facts_label"> - <?php echo WT_Gedcom_Tag::getLabel('NOTE'); ?> + <?php echo GedcomTag::getLabel('NOTE'); ?> </td> <td class="facts_value"> <a href="#" onclick="add_new_record('<?php echo $controller->record->getXref(); ?>','NOTE'); return false;"> @@ -91,7 +91,7 @@ class NotesTabModule extends Module implements ModuleTabInterface { </tr> <tr> <td class="facts_label"> - <?php echo WT_Gedcom_Tag::getLabel('SHARED_NOTE'); ?> + <?php echo GedcomTag::getLabel('SHARED_NOTE'); ?> </td> <td class="facts_value"> <a href="#" onclick="add_new_record('<?php echo $controller->record->getXref(); ?>','SHARED_NOTE'); return false;"> diff --git a/app/Module/RelativesTabModule.php b/app/Module/RelativesTabModule.php index 1c05c54674..24f74ee42b 100644 --- a/app/Module/RelativesTabModule.php +++ b/app/Module/RelativesTabModule.php @@ -184,7 +184,7 @@ class RelativesTabModule extends Module implements ModuleTabInterface { </td> <td class="facts_value<?php echo $class; ?>"> - <?php echo WT_Gedcom_Tag::getLabelValue($fact->getTag(), $fact->getDate()->display() . ' — ' . $fact->getPlace()->getFullName()); ?> + <?php echo GedcomTag::getLabelValue($fact->getTag(), $fact->getDate()->display() . ' — ' . $fact->getPlace()->getFullName()); ?> </td> </tr> <?php diff --git a/app/Module/ResearchTaskModule.php b/app/Module/ResearchTaskModule.php index 0a1194feaa..07aecbaf77 100644 --- a/app/Module/ResearchTaskModule.php +++ b/app/Module/ResearchTaskModule.php @@ -89,12 +89,12 @@ class ResearchTaskModule extends Module implements ModuleBlockInterface { $content .= '<table id="' . $table_id . '" style="visibility:hidden;">'; $content .= '<thead><tr>'; $content .= '<th>DATE</th>'; //hidden by datables code - $content .= '<th>' . WT_Gedcom_Tag::getLabel('DATE') . '</th>'; + $content .= '<th>' . GedcomTag::getLabel('DATE') . '</th>'; $content .= '<th>' . I18N::translate('Record') . '</th>'; if ($show_unassigned || $show_other) { $content .= '<th>' . I18N::translate('Username') . '</th>'; } - $content .= '<th>' . WT_Gedcom_Tag::getLabel('TEXT') . '</th>'; + $content .= '<th>' . GedcomTag::getLabel('TEXT') . '</th>'; $content .= '</tr></thead><tbody>'; $found = false; diff --git a/app/Module/SlideShowModule.php b/app/Module/SlideShowModule.php index 6410469e40..9d4e1462c4 100644 --- a/app/Module/SlideShowModule.php +++ b/app/Module/SlideShowModule.php @@ -280,7 +280,7 @@ class SlideShowModule extends Module implements ModuleBlockInterface { ?> </td> <td class="optionbox"> - <center><b><?php echo WT_Gedcom_Tag::getLabel('FORM'); ?></b></center> + <center><b><?php echo GedcomTag::getLabel('FORM'); ?></b></center> <table class="width100"> <tr> <td class="width33"> @@ -359,13 +359,13 @@ class SlideShowModule extends Module implements ModuleBlockInterface { </tr> </table> <br> - <center><b><?php echo WT_Gedcom_Tag::getLabel('TYPE'); ?></b></center> + <center><b><?php echo GedcomTag::getLabel('TYPE'); ?></b></center> <table class="width100"> <tr> <?php //-- Build the list of checkboxes $i = 0; - foreach (WT_Gedcom_Tag::getFileFormTypes() as $typeName => $typeValue) { + foreach (GedcomTag::getFileFormTypes() as $typeName => $typeValue) { $i++; if ($i > 3) { $i = 1; diff --git a/app/Module/SourcesTabModule.php b/app/Module/SourcesTabModule.php index fa02dd799a..7d8ff57751 100644 --- a/app/Module/SourcesTabModule.php +++ b/app/Module/SourcesTabModule.php @@ -77,7 +77,7 @@ class SourcesTabModule extends Module implements ModuleTabInterface { ?> <tr> <td class="facts_label"> - <?php echo WT_Gedcom_Tag::getLabel('SOUR'); ?> + <?php echo GedcomTag::getLabel('SOUR'); ?> </td> <td class="facts_value"> <a href="#" onclick="add_new_record('<?php echo $controller->record->getXref(); ?>','SOUR'); return false;"> diff --git a/app/Module/StoriesModule.php b/app/Module/StoriesModule.php index 11fd737cf6..9790b33ef6 100644 --- a/app/Module/StoriesModule.php +++ b/app/Module/StoriesModule.php @@ -159,7 +159,7 @@ class StoriesModule extends Module implements ModuleTabInterface, ModuleConfigIn } set_block_setting($block_id, 'title', Filter::post('title')); set_block_setting($block_id, 'story_body', Filter::post('story_body')); - $languages = Filter::postArray('lang', null, array_keys(I18N::installed_languages())); + $languages = Filter::postArray('lang', null, array_keys(I18N::installedLanguages())); set_block_setting($block_id, 'languages', implode(',', $languages)); $this->config(); } else { diff --git a/app/Module/TopSurnamesModule.php b/app/Module/TopSurnamesModule.php index 4b9cb3b4d0..b9cbd28b77 100644 --- a/app/Module/TopSurnamesModule.php +++ b/app/Module/TopSurnamesModule.php @@ -63,7 +63,7 @@ class TopSurnamesModule extends Module implements ModuleBlockInterface { $all_surnames = array(); $i = 0; foreach (array_keys($top_surnames) as $top_surname) { - $all_surnames = array_merge($all_surnames, WT_Query_Name::surnames($top_surname, '', false, false, WT_GED_ID)); + $all_surnames = array_merge($all_surnames, QueryName::surnames($top_surname, '', false, false, WT_GED_ID)); if (++$i == $num) { break; } diff --git a/app/Module/YahrzeitModule.php b/app/Module/YahrzeitModule.php index 5039a1e3f7..09299db458 100644 --- a/app/Module/YahrzeitModule.php +++ b/app/Module/YahrzeitModule.php @@ -149,12 +149,12 @@ class YahrzeitModule extends Module implements ModuleBlockInterface { $content .= '<div class="loading-image"> </div>'; $content .= '<table id="' . $table_id . '" class="width100" style="visibility:hidden;">'; $content .= '<thead><tr>'; - $content .= '<th>' . WT_Gedcom_Tag::getLabel('NAME') . '</th>'; - $content .= '<th>' . WT_Gedcom_Tag::getLabel('NAME') . '</th>'; - $content .= '<th>' . WT_Gedcom_Tag::getLabel('DEAT') . '</th>'; + $content .= '<th>' . GedcomTag::getLabel('NAME') . '</th>'; + $content .= '<th>' . GedcomTag::getLabel('NAME') . '</th>'; + $content .= '<th>' . GedcomTag::getLabel('DEAT') . '</th>'; $content .= '<th>DEAT</th>'; $content .= '<th><i class="icon-reminder" title="' . I18N::translate('Anniversary') . '"></i></th>'; - $content .= '<th>' . WT_Gedcom_Tag::getLabel('_YART') . '</th>'; + $content .= '<th>' . GedcomTag::getLabel('_YART') . '</th>'; $content .= '<th>_YART</th>'; $content .= '</tr></thead><tbody>'; diff --git a/app/Query/Media.php b/app/Query/QueryMedia.php index 13d6cc3559..3bf4b1bee6 100644 --- a/app/Query/Media.php +++ b/app/Query/QueryMedia.php @@ -17,13 +17,13 @@ namespace Fisharebest\Webtrees; */ /** - * Class WT_Query_Media - generate lists of files for admin_media.php + * Class QueryMedia - generate lists of files for admin_media.php * * @package webtrees * @copyright (c) 2014 webtrees development team * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 */ -class WT_Query_Media { +class QueryMedia { /** * Generate a list of all the folders in the current tree - for the media list. * @@ -109,7 +109,7 @@ class WT_Query_Media { $args[] = Filter::escapeLike($folder); break; default: - throw new \Exception('Bad argument (subfolders=' . $subfolders . ') in WT_Query_Media::mediaList()'); + throw new \Exception('Bad argument (subfolders=' . $subfolders . ') in QueryMedia::mediaList()'); } // Apply search terms @@ -127,7 +127,7 @@ class WT_Query_Media { $sql .= " ORDER BY m_titl"; break; default: - throw new \Exception('Bad argument (sort=' . $sort . ') in WT_Query_Media::mediaList()'); + throw new \Exception('Bad argument (sort=' . $sort . ') in QueryMedia::mediaList()'); } $rows = Database::prepare($sql)->execute($args)->fetchAll(); diff --git a/app/Query/Name.php b/app/Query/QueryName.php index 54ccbe2c54..16bb50f562 100644 --- a/app/Query/Name.php +++ b/app/Query/QueryName.php @@ -17,13 +17,13 @@ namespace Fisharebest\Webtrees; */ /** - * Class WT_Query_Name - generate lists for indilist.php and famlist.php + * Class QueryName - generate lists for indilist.php and famlist.php * * @package webtrees * @copyright (c) 2014 webtrees development team * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 */ -class WT_Query_Name { +class QueryName { /** * Get a list of initial letters, for lists of names. * diff --git a/app/Report/ReportBase.php b/app/Report/ReportBase.php index a246229ab9..a5227922b4 100644 --- a/app/Report/ReportBase.php +++ b/app/Report/ReportBase.php @@ -1539,13 +1539,13 @@ function varStartHandler($attrs) { // n TYPE This text if string $tfact = $type; } - $var = str_replace(array("@fact", "@desc"), array(WT_Gedcom_Tag::getLabel($tfact), $desc), $var); + $var = str_replace(array("@fact", "@desc"), array(GedcomTag::getLabel($tfact), $desc), $var); if (preg_match('/^I18N::number\((.+)\)$/', $var, $match)) { $var = I18N::number($match[1]); } elseif (preg_match('/^I18N::translate\(\'(.+)\'\)$/', $var, $match)) { $var = I18N::translate($match[1]); } elseif (preg_match('/^I18N::translate_c\(\'(.+)\', *\'(.+)\'\)$/', $var, $match)) { - $var = I18N::translate_c($match[1], $match[2]); + $var = I18N::translateContext($match[1], $match[2]); } } // Check if variable is set as a date and reformat the date @@ -1741,7 +1741,7 @@ function setVarStartHandler($attrs) { } elseif (preg_match('/^I18N::translate\(\'(.+)\'\)$/', $value, $match)) { $value = I18N::translate($match[1]); } elseif (preg_match('/^I18N::translate_c\(\'(.+)\', *\'(.+)\'\)$/', $value, $match)) { - $value = I18N::translate_c($match[1], $match[2]); + $value = I18N::translateContext($match[1], $match[2]); } // Arithmetic functions if (preg_match("/(\d+)\s*([\-\+\*\/])\s*(\d+)/", $value, $match)) { diff --git a/app/Stats.php b/app/Stats.php index 6fbf82f4f1..983483dc5f 100644 --- a/app/Stats.php +++ b/app/Stats.php @@ -830,13 +830,13 @@ class Stats { } elseif ($tot_u > 0) { $chd = $this->arrayToExtendedEncoding(array(4095 * $tot_u / $tot, 4095 * $tot_f / $tot, 4095 * $tot_m / $tot)); $chl = - I18N::translate_c('unknown people', 'Unknown') . ' - ' . $per_u . '|' . + I18N::translateContext('unknown people', 'Unknown') . ' - ' . $per_u . '|' . I18N::translate('Females') . ' - ' . $per_f . '|' . I18N::translate('Males') . ' - ' . $per_m; $chart_title = I18N::translate('Males') . ' - ' . $per_m . I18N::$list_separator . I18N::translate('Females') . ' - ' . $per_f . I18N::$list_separator . - I18N::translate_c('unknown people', 'Unknown') . ' - ' . $per_u; + I18N::translateContext('unknown people', 'Unknown') . ' - ' . $per_u; return "<img src=\"https://chart.googleapis.com/chart?cht=p3&chd=e:{$chd}&chs={$size}&chco={$color_unknown},{$color_female},{$color_male}&chf=bg,s,ffffff00&chl={$chl}\" width=\"{$sizes[0]}\" height=\"{$sizes[1]}\" alt=\"" . $chart_title . "\" title=\"" . $chart_title . "\" />"; } else { $chd = $this->arrayToExtendedEncoding(array(4095 * $tot_f / $tot, 4095 * $tot_m / $tot)); @@ -1221,8 +1221,8 @@ class Stats { asort($media); foreach ($media as $type => $count) { $mediaCounts[] = round(100 * $count / $tot, 0); - $mediaTypes .= WT_Gedcom_Tag::getFileFormTypeValue($type) . ' - ' . I18N::number($count) . '|'; - $chart_title .= WT_Gedcom_Tag::getFileFormTypeValue($type) . ' (' . $count . '), '; + $mediaTypes .= GedcomTag::getFileFormTypeValue($type) . ' - ' . I18N::number($count) . '|'; + $chart_title .= GedcomTag::getFileFormTypeValue($type) . ' (' . $count . '), '; } $chart_title = substr($chart_title, 0, -2); $chd = $this->arrayToExtendedEncoding($mediaCounts); @@ -1439,7 +1439,7 @@ class Stats { } // Get the country names for each language $country_to_iso3166 = array(); - foreach (I18N::installed_languages() as $code => $lang) { + foreach (I18N::installedLanguages() as $code => $lang) { I18N::init($code); $countries = $this->getAllCountries(); foreach ($this->iso3166() as $three => $two) { @@ -1456,7 +1456,7 @@ class Stats { $chart_title = I18N::translate('Surname distribution chart') . ': ' . $surname; // Count how many people are events in each country $surn_countries = array(); - $indis = WT_Query_Name::individuals(I18N::strtoupper($surname), '', '', false, false, WT_GED_ID); + $indis = QueryName::individuals(I18N::strtoupper($surname), '', '', false, false, WT_GED_ID); foreach ($indis as $person) { if (preg_match_all('/^2 PLAC (?:.*, *)*(.*)/m', $person->getGedcom(), $matches)) { // webtrees uses 3 letter country codes and localised country names, but google uses 2 letter codes. @@ -1572,7 +1572,7 @@ class Stats { $i = 1; // Get the country names for each language $country_names = array(); - foreach (I18N::installed_languages() as $code => $lang) { + foreach (I18N::installedLanguages() as $code => $lang) { I18N::init($code); $all_countries = $this->getAllCountries(); foreach ($all_countries as $country_code => $country_name) { @@ -2664,7 +2664,7 @@ class Stats { if (isset($eventTypes[$row['fact']])) { $result = $eventTypes[$row['fact']]; } else { - $result = WT_Gedcom_Tag::getLabel($row['fact']); + $result = GedcomTag::getLabel($row['fact']); } break; case 'name': @@ -4684,7 +4684,7 @@ class Stats { $counts[] = round(4095 * $unknown / ($max + 1)); $chd = $this->arrayToExtendedEncoding($counts); $chm .= 't' . $unknown . ',000000,0,' . $i . ',11,1'; - $chxl .= I18N::translate_c('unknown century', 'Unknown') . "|1:||" . I18N::translate('century') . "|2:|0|"; + $chxl .= I18N::translateContext('unknown century', 'Unknown') . "|1:||" . I18N::translate('century') . "|2:|0|"; $step = $max + 1; for ($d = (int) ($max + 1); $d > 0; $d--) { if (($max + 1) < ($d * 10 + 1) && fmod(($max + 1), $d) == 0) { @@ -4833,7 +4833,7 @@ class Stats { // Note that we count/display SPFX SURN, but sort/group under just SURN $surnames = array(); foreach (array_keys($surname_list) as $surname) { - $surnames = array_merge($surnames, WT_Query_Name::surnames($surname, '', false, false, WT_GED_ID)); + $surnames = array_merge($surnames, QueryName::surnames($surname, '', false, false, WT_GED_ID)); } return format_surname_list($surnames, ($type == 'list' ? 1 : 2), $show_tot, 'indilist.php', $this->tree); } @@ -4933,7 +4933,7 @@ class Stats { if ($n >= $maxtoshow) { break; } - $all_surnames = array_merge($all_surnames, WT_Query_Name::surnames(I18N::strtoupper($surname), '', false, false, WT_GED_ID)); + $all_surnames = array_merge($all_surnames, QueryName::surnames(I18N::strtoupper($surname), '', false, false, WT_GED_ID)); } $tot = 0; foreach ($surnames as $surname) { @@ -5087,7 +5087,7 @@ class Stats { }); jQuery("#' . $table_id . '").css("visibility", "visible"); '); - $lookup = array('M' => I18N::translate('Male'), 'F' => I18N::translate('Female'), 'U' => I18N::translate_c('unknown gender', 'Unknown'), 'B' => I18N::translate('All')); + $lookup = array('M' => I18N::translate('Male'), 'F' => I18N::translate('Female'), 'U' => I18N::translateContext('unknown gender', 'Unknown'), 'B' => I18N::translate('All')); return '<table id="' . $table_id . '" class="givn-list"><thead><tr><th class="ui-state-default" colspan="3">' . $lookup[$sex] . '</th></tr><tr><th>' . I18N::translate('Name') . '</th><th>' . I18N::translate('Count') . '</th><th>COUNT</th></tr></thead><tbody>' . implode('', $common) . '</tbody></table>'; case 'list': return '<ul>' . implode('', $common) . '</ul>'; @@ -6343,47 +6343,47 @@ class Stats { // The current chart engine (Google charts) can't handle <sup></sup> markup switch ($century) { case 21: - return strip_tags(I18N::translate_c('CENTURY', '21st')); + return strip_tags(I18N::translateContext('CENTURY', '21st')); case 20: - return strip_tags(I18N::translate_c('CENTURY', '20th')); + return strip_tags(I18N::translateContext('CENTURY', '20th')); case 19: - return strip_tags(I18N::translate_c('CENTURY', '19th')); + return strip_tags(I18N::translateContext('CENTURY', '19th')); case 18: - return strip_tags(I18N::translate_c('CENTURY', '18th')); + return strip_tags(I18N::translateContext('CENTURY', '18th')); case 17: - return strip_tags(I18N::translate_c('CENTURY', '17th')); + return strip_tags(I18N::translateContext('CENTURY', '17th')); case 16: - return strip_tags(I18N::translate_c('CENTURY', '16th')); + return strip_tags(I18N::translateContext('CENTURY', '16th')); case 15: - return strip_tags(I18N::translate_c('CENTURY', '15th')); + return strip_tags(I18N::translateContext('CENTURY', '15th')); case 14: - return strip_tags(I18N::translate_c('CENTURY', '14th')); + return strip_tags(I18N::translateContext('CENTURY', '14th')); case 13: - return strip_tags(I18N::translate_c('CENTURY', '13th')); + return strip_tags(I18N::translateContext('CENTURY', '13th')); case 12: - return strip_tags(I18N::translate_c('CENTURY', '12th')); + return strip_tags(I18N::translateContext('CENTURY', '12th')); case 11: - return strip_tags(I18N::translate_c('CENTURY', '11th')); + return strip_tags(I18N::translateContext('CENTURY', '11th')); case 10: - return strip_tags(I18N::translate_c('CENTURY', '10th')); + return strip_tags(I18N::translateContext('CENTURY', '10th')); case 9: - return strip_tags(I18N::translate_c('CENTURY', '9th')); + return strip_tags(I18N::translateContext('CENTURY', '9th')); case 8: - return strip_tags(I18N::translate_c('CENTURY', '8th')); + return strip_tags(I18N::translateContext('CENTURY', '8th')); case 7: - return strip_tags(I18N::translate_c('CENTURY', '7th')); + return strip_tags(I18N::translateContext('CENTURY', '7th')); case 6: - return strip_tags(I18N::translate_c('CENTURY', '6th')); + return strip_tags(I18N::translateContext('CENTURY', '6th')); case 5: - return strip_tags(I18N::translate_c('CENTURY', '5th')); + return strip_tags(I18N::translateContext('CENTURY', '5th')); case 4: - return strip_tags(I18N::translate_c('CENTURY', '4th')); + return strip_tags(I18N::translateContext('CENTURY', '4th')); case 3: - return strip_tags(I18N::translate_c('CENTURY', '3rd')); + return strip_tags(I18N::translateContext('CENTURY', '3rd')); case 2: - return strip_tags(I18N::translate_c('CENTURY', '2nd')); + return strip_tags(I18N::translateContext('CENTURY', '2nd')); case 1: - return strip_tags(I18N::translate_c('CENTURY', '1st')); + return strip_tags(I18N::translateContext('CENTURY', '1st')); default: return ($century - 1) . '01-' . $century . '00'; } diff --git a/app/Theme/BaseTheme.php b/app/Theme/BaseTheme.php index 0643517895..0b7a984020 100644 --- a/app/Theme/BaseTheme.php +++ b/app/Theme/BaseTheme.php @@ -594,7 +594,7 @@ abstract class BaseTheme { * @return string */ public function html() { - return '<html ' . I18N::html_markup() . '>'; + return '<html ' . I18N::htmlAttributes() . '>'; } /** @@ -634,7 +634,7 @@ abstract class BaseTheme { $icon = 'images/facts/' . $fact->getTag() . '.png'; $dir = substr($this->assetUrl(), strlen(WT_STATIC_URL)); if (file_exists($dir . $icon)) { - return '<img src="' . $this->assetUrl() . $icon . '" title="' . WT_Gedcom_Tag::getLabel($fact->getTag()) . '">'; + return '<img src="' . $this->assetUrl() . $icon . '" title="' . GedcomTag::getLabel($fact->getTag()) . '">'; } elseif (file_exists($dir . 'images/facts/NULL.png')) { // Spacer image - for alignment - until we move to a sprite. return '<img src="' . Theme::theme()->assetUrl() . 'images/facts/NULL.png">'; @@ -1293,7 +1293,7 @@ abstract class BaseTheme { protected function menuLanguages() { $menu = new Menu(I18N::translate('Language'), '#', 'menu-language'); - foreach (I18N::installed_languages() as $lang => $name) { + foreach (I18N::installedLanguages() as $lang => $name) { $submenu = new Menu($name, get_query_url(array('lang' => $lang), '&'), 'menu-language-' . $lang); if (WT_LOCALE === $lang) { $submenu->addClass('', '', 'active'); |
