@@ -13,7 +13,7 @@ discard block |
||
| 13 | 13 | * You should have received a copy of the GNU General Public License |
| 14 | 14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
| 15 | 15 | */ |
| 16 | -declare(strict_types=1); |
|
| 16 | +declare(strict_types = 1); |
|
| 17 | 17 | |
| 18 | 18 | namespace Fisharebest\Webtrees\Http\Controllers; |
| 19 | 19 | |
@@ -68,7 +68,7 @@ discard block |
||
| 68 | 68 | if ($individual !== null) { |
| 69 | 69 | $xrefs[] = $addxref; |
| 70 | 70 | if ($addfam) { |
| 71 | - $xrefs = array_merge($xrefs, $this->closeFamily($individual)); |
|
| 71 | + $xrefs = array_merge($xrefs, $this->closeFamily($individual)); |
|
| 72 | 72 | } |
| 73 | 73 | } |
| 74 | 74 | |
@@ -13,7 +13,7 @@ discard block |
||
| 13 | 13 | * You should have received a copy of the GNU General Public License |
| 14 | 14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
| 15 | 15 | */ |
| 16 | -declare(strict_types=1); |
|
| 16 | +declare(strict_types = 1); |
|
| 17 | 17 | |
| 18 | 18 | namespace Fisharebest\Webtrees\Http\Controllers; |
| 19 | 19 | |
@@ -360,7 +360,7 @@ discard block |
||
| 360 | 360 | $html = sprintf('<div id="childarrow"><a href="#" class="menuselect %s"></a><div id="childbox-pedigree">', $this->arrows->menu); |
| 361 | 361 | |
| 362 | 362 | foreach ($families as $family) { |
| 363 | - $html .= '<span class="name1">' . I18N::translate('Family') . '</span>'; |
|
| 363 | + $html .= '<span class="name1">' . I18N::translate('Family') . '</span>'; |
|
| 364 | 364 | $spouse = $family->getSpouse($this->root); |
| 365 | 365 | if ($spouse) { |
| 366 | 366 | $html .= '<a class="name1" href="' . e(route('pedigree', [ |
@@ -420,7 +420,7 @@ discard block |
||
| 420 | 420 | $html = ''; |
| 421 | 421 | if ($this->chartHasAncestors) { |
| 422 | 422 | if ($this->nodes[$index]['indi'] && $this->nodes[$index]['indi']->getChildFamilies()) { |
| 423 | - $html .= '<div class="ancestorarrow">'; |
|
| 423 | + $html .= '<div class="ancestorarrow">'; |
|
| 424 | 424 | $rootParentId = 1; |
| 425 | 425 | if ($index > (int) ($this->treesize / 2) + (int) ($this->treesize / 4)) { |
| 426 | 426 | $rootParentId++; |
@@ -85,7 +85,7 @@ discard block |
||
| 85 | 85 | ]); |
| 86 | 86 | break; |
| 87 | 87 | case 'descendants': |
| 88 | - $title = I18N::translate('Descendants of %s', $person->getFullName()); |
|
| 88 | + $title = I18N::translate('Descendants of %s', $person->getFullName()); |
|
| 89 | 89 | $chart_url = route('descendants-chart', [ |
| 90 | 90 | 'xref' => $person->getXref(), |
| 91 | 91 | 'ged' => $person->getTree()->getName(), |
@@ -98,7 +98,7 @@ discard block |
||
| 98 | 98 | ]); |
| 99 | 99 | break; |
| 100 | 100 | case 'hourglass': |
| 101 | - $title = I18N::translate('Hourglass chart of %s', $person->getFullName()); |
|
| 101 | + $title = I18N::translate('Hourglass chart of %s', $person->getFullName()); |
|
| 102 | 102 | $chart_url = route('hourglass-chart', [ |
| 103 | 103 | 'xref' => $person->getXref(), |
| 104 | 104 | 'ged' => $person->getTree()->getName(), |
@@ -13,7 +13,7 @@ discard block |
||
| 13 | 13 | * You should have received a copy of the GNU General Public License |
| 14 | 14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
| 15 | 15 | */ |
| 16 | -declare(strict_types=1); |
|
| 16 | +declare(strict_types = 1); |
|
| 17 | 17 | |
| 18 | 18 | namespace Fisharebest\Webtrees\Http\Controllers; |
| 19 | 19 | |
@@ -58,7 +58,7 @@ discard block |
||
| 58 | 58 | $maximum_generations = (int) $tree->getPreference('MAX_DESCENDANCY_GENERATIONS', self::DEFAULT_MAXIMUM_GENERATIONS); |
| 59 | 59 | $default_generations = (int) $tree->getPreference('DEFAULT_PEDIGREE_GENERATIONS', self::DEFAULT_GENERATIONS); |
| 60 | 60 | |
| 61 | - $generations = (int) $request->get('generations', $default_generations); |
|
| 61 | + $generations = (int) $request->get('generations', $default_generations); |
|
| 62 | 62 | |
| 63 | 63 | $generations = min($generations, $maximum_generations); |
| 64 | 64 | $generations = max($generations, self::MINIMUM_GENERATIONS); |
@@ -220,7 +220,7 @@ discard block |
||
| 220 | 220 | echo '<table cellspacing="0" cellpadding="0" border="0" style="position: relative; top: auto; float: ' . $tablealign . ';">'; |
| 221 | 221 | for ($i = 0; $i < $ct; $i++) { |
| 222 | 222 | $individual2 = $children[$i]; |
| 223 | - $chil = $individual2->getXref(); |
|
| 223 | + $chil = $individual2->getXref(); |
|
| 224 | 224 | echo '<tr>'; |
| 225 | 225 | echo '<td id="td_', e($chil), '" class="', I18N::direction(), '" style="text-align:', $otablealign, '">'; |
| 226 | 226 | $this->printDescendency($individual2, $generation + 1, $generations, $show_spouse, false); |
@@ -13,7 +13,7 @@ discard block |
||
| 13 | 13 | * You should have received a copy of the GNU General Public License |
| 14 | 14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
| 15 | 15 | */ |
| 16 | -declare(strict_types=1); |
|
| 16 | +declare(strict_types = 1); |
|
| 17 | 17 | |
| 18 | 18 | namespace Fisharebest\Webtrees\Http\Controllers; |
| 19 | 19 | |
@@ -130,7 +130,7 @@ discard block |
||
| 130 | 130 | ->setPreference('TIMEZONE', $time_zone) |
| 131 | 131 | ->setPreference('visibleonline', $visible_online); |
| 132 | 132 | |
| 133 | - $tree->setUserPreference($user,'rootid', $rootid); |
|
| 133 | + $tree->setUserPreference($user, 'rootid', $rootid); |
|
| 134 | 134 | |
| 135 | 135 | // Switch to the new theme now |
| 136 | 136 | Session::put('theme_id', $theme); |
@@ -146,7 +146,7 @@ discard block |
||
| 146 | 146 | <?= I18N::translate('Theme') ?> |
| 147 | 147 | </label> |
| 148 | 148 | <div class="col-sm-9 wt-page-options-value"> |
| 149 | - <?= Bootstrap4::select($themes, $user->getPreference('theme'), ['id' => 'theme', 'name' => 'theme', 'aria-describedby' => 'theme-description',]) ?> |
|
| 149 | + <?= Bootstrap4::select($themes, $user->getPreference('theme'), ['id' => 'theme', 'name' => 'theme', 'aria-describedby' => 'theme-description', ]) ?> |
|
| 150 | 150 | <p class="small text-muted" id="theme-description"> |
| 151 | 151 | <?= /* I18N: Help text for the "Default theme" site configuration setting */ |
| 152 | 152 | I18N::translate('You can change the appearance of webtrees using “themes”. Each theme has a different style, layout, color scheme, etc.') ?> |
@@ -160,7 +160,7 @@ discard block |
||
| 160 | 160 | <?= I18N::translate('Contact method') ?> |
| 161 | 161 | </label> |
| 162 | 162 | <div class="col-sm-9 wt-page-options-value"> |
| 163 | - <?= Bootstrap4::select($contact_methods, $user->getPreference('contactmethod'), ['id' => 'contact-method', 'name' => 'contact_method', 'aria-describedby' => 'contact-method-description',]) ?> |
|
| 163 | + <?= Bootstrap4::select($contact_methods, $user->getPreference('contactmethod'), ['id' => 'contact-method', 'name' => 'contact_method', 'aria-describedby' => 'contact-method-description', ]) ?> |
|
| 164 | 164 | <p class="small text-muted" id="contact-method-description"> |
| 165 | 165 | <?= I18N::translate('Site members can send each other messages. You can choose to how these messages are sent to you, or choose not receive them at all.') ?> |
| 166 | 166 | </p> |
@@ -13,7 +13,7 @@ |
||
| 13 | 13 | * You should have received a copy of the GNU General Public License |
| 14 | 14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
| 15 | 15 | */ |
| 16 | -declare(strict_types=1); |
|
| 16 | +declare(strict_types = 1); |
|
| 17 | 17 | |
| 18 | 18 | namespace Fisharebest\Webtrees\Http\Controllers; |
| 19 | 19 | |
@@ -111,24 +111,24 @@ |
||
| 111 | 111 | * @return Individual[] |
| 112 | 112 | */ |
| 113 | 113 | protected function allAncestors(Individual $individual): array { |
| 114 | - /** @var Individual[] $ancestors */ |
|
| 115 | - $ancestors = [ |
|
| 116 | - 1 => $individual, |
|
| 117 | - ]; |
|
| 114 | + /** @var Individual[] $ancestors */ |
|
| 115 | + $ancestors = [ |
|
| 116 | + 1 => $individual, |
|
| 117 | + ]; |
|
| 118 | 118 | |
| 119 | - do { |
|
| 120 | - $sosa = key($ancestors); |
|
| 119 | + do { |
|
| 120 | + $sosa = key($ancestors); |
|
| 121 | 121 | |
| 122 | 122 | $family = $ancestors[$sosa]->getPrimaryChildFamily(); |
| 123 | 123 | |
| 124 | 124 | if ($family !== null) { |
| 125 | - if ($family->getHusband() !== null) { |
|
| 126 | - $ancestors[$sosa * 2] = $family->getHusband(); |
|
| 127 | - } |
|
| 128 | - if ($family->getWife() !== null) { |
|
| 129 | - $ancestors[$sosa * 2 + 1] = $family->getWife(); |
|
| 130 | - } |
|
| 131 | - } |
|
| 125 | + if ($family->getHusband() !== null) { |
|
| 126 | + $ancestors[$sosa * 2] = $family->getHusband(); |
|
| 127 | + } |
|
| 128 | + if ($family->getWife() !== null) { |
|
| 129 | + $ancestors[$sosa * 2 + 1] = $family->getWife(); |
|
| 130 | + } |
|
| 131 | + } |
|
| 132 | 132 | } while (next($ancestors)); |
| 133 | 133 | |
| 134 | 134 | return $ancestors; |
@@ -13,7 +13,7 @@ discard block |
||
| 13 | 13 | * You should have received a copy of the GNU General Public License |
| 14 | 14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
| 15 | 15 | */ |
| 16 | -declare(strict_types=1); |
|
| 16 | +declare(strict_types = 1); |
|
| 17 | 17 | |
| 18 | 18 | namespace Fisharebest\Webtrees\Http\Controllers; |
| 19 | 19 | |
@@ -162,7 +162,7 @@ discard block |
||
| 162 | 162 | $sdx = Soundex::russell($surname); |
| 163 | 163 | if ($sdx !== null) { |
| 164 | 164 | foreach (explode(':', $sdx) as $value) { |
| 165 | - $sql .= " OR n_soundex_surn_std LIKE CONCAT('%', ?, '%')"; |
|
| 165 | + $sql .= " OR n_soundex_surn_std LIKE CONCAT('%', ?, '%')"; |
|
| 166 | 166 | $args[] = $value; |
| 167 | 167 | } |
| 168 | 168 | } |
@@ -172,7 +172,7 @@ discard block |
||
| 172 | 172 | $sdx = Soundex::daitchMokotoff($surname); |
| 173 | 173 | if ($sdx !== null) { |
| 174 | 174 | foreach (explode(':', $sdx) as $value) { |
| 175 | - $sql .= " OR n_soundex_surn_dm LIKE CONCAT('%', ?, '%')"; |
|
| 175 | + $sql .= " OR n_soundex_surn_dm LIKE CONCAT('%', ?, '%')"; |
|
| 176 | 176 | $args[] = $value; |
| 177 | 177 | } |
| 178 | 178 | } |
@@ -43,14 +43,14 @@ |
||
| 43 | 43 | <?php endforeach ?> |
| 44 | 44 | </td> |
| 45 | 45 | |
| 46 | - <td class="text-center" data-sort="<?= array_sum(array_map(function(array $x) { return count($x); }, $surns)) ?>"> |
|
| 46 | + <td class="text-center" data-sort="<?= array_sum(array_map(function (array $x) { return count($x); }, $surns)) ?>"> |
|
| 47 | 47 | <?php foreach ($surns as $indis): ?> |
| 48 | 48 | <?= I18N::number(count($indis)) ?> |
| 49 | 49 | <br> |
| 50 | 50 | <?php endforeach ?> |
| 51 | 51 | |
| 52 | 52 | <?php if (count($surns) > 1): ?> |
| 53 | - <?= I18N::number(array_sum(array_map(function(array $x) { return count($x); }, $surns))) ?> |
|
| 53 | + <?= I18N::number(array_sum(array_map(function (array $x) { return count($x); }, $surns))) ?> |
|
| 54 | 54 | <?php endif ?> |
| 55 | 55 | </td> |
| 56 | 56 | </tr> |
@@ -12,7 +12,8 @@ discard block |
||
| 12 | 12 | <th> |
| 13 | 13 | <?php if ($route == 'family-list'):?> |
| 14 | 14 | <?= I18N::translate('Spouses') ?> |
| 15 | - <?php else: ?> |
|
| 15 | + <?php else { |
|
| 16 | + : ?> |
|
| 16 | 17 | <?= I18N::translate('Individuals') ?> |
| 17 | 18 | <?php endif ?> |
| 18 | 19 | </th> |
@@ -43,7 +44,9 @@ discard block |
||
| 43 | 44 | <?php endforeach ?> |
| 44 | 45 | </td> |
| 45 | 46 | |
| 46 | - <td class="text-center" data-sort="<?= array_sum(array_map(function(array $x) { return count($x); }, $surns)) ?>"> |
|
| 47 | + <td class="text-center" data-sort="<?= array_sum(array_map(function(array $x) { return count($x); |
|
| 48 | +} |
|
| 49 | +}, $surns)) ?>"> |
|
| 47 | 50 | <?php foreach ($surns as $indis): ?> |
| 48 | 51 | <?= I18N::number(count($indis)) ?> |
| 49 | 52 | <br> |