@@ -273,40 +273,40 @@ discard block |
||
273 | 273 | |
274 | 274 | $level1type = $edit_fact->getTag(); |
275 | 275 | switch ($record::RECORD_TYPE) { |
276 | - case 'REPO': |
|
277 | - // REPO:NAME facts may take a NOTE (but the REPO record may not). |
|
278 | - if ($level1type === 'NAME') { |
|
279 | - FunctionsEdit::printAddLayer('NOTE'); |
|
280 | - FunctionsEdit::printAddLayer('SHARED_NOTE'); |
|
276 | + case 'REPO': |
|
277 | + // REPO:NAME facts may take a NOTE (but the REPO record may not). |
|
278 | + if ($level1type === 'NAME') { |
|
279 | + FunctionsEdit::printAddLayer('NOTE'); |
|
280 | + FunctionsEdit::printAddLayer('SHARED_NOTE'); |
|
281 | + } |
|
282 | + break; |
|
283 | + case 'FAM': |
|
284 | + case 'INDI': |
|
285 | + // FAM and INDI records have real facts. They can take NOTE/SOUR/OBJE/etc. |
|
286 | + if ($level1type !== 'SEX' && $level1type !== 'NOTE' && $level1type !== 'ALIA') { |
|
287 | + if ($level1type !== 'SOUR') { |
|
288 | + FunctionsEdit::printAddLayer('SOUR'); |
|
281 | 289 | } |
282 | - break; |
|
283 | - case 'FAM': |
|
284 | - case 'INDI': |
|
285 | - // FAM and INDI records have real facts. They can take NOTE/SOUR/OBJE/etc. |
|
286 | - if ($level1type !== 'SEX' && $level1type !== 'NOTE' && $level1type !== 'ALIA') { |
|
287 | - if ($level1type !== 'SOUR') { |
|
288 | - FunctionsEdit::printAddLayer('SOUR'); |
|
289 | - } |
|
290 | - if ($level1type !== 'OBJE') { |
|
291 | - FunctionsEdit::printAddLayer('OBJE'); |
|
292 | - } |
|
293 | - FunctionsEdit::printAddLayer('NOTE'); |
|
294 | - FunctionsEdit::printAddLayer('SHARED_NOTE', 2, $level1type); |
|
295 | - if ($level1type !== 'ASSO' && $level1type !== 'NOTE' && $level1type !== 'SOUR') { |
|
296 | - FunctionsEdit::printAddLayer('ASSO'); |
|
297 | - } |
|
298 | - // allow to add godfather and godmother for CHR fact or best man and bridesmaid for MARR fact in one window |
|
299 | - if (in_array($level1type, Config::twoAssociates())) { |
|
300 | - FunctionsEdit::printAddLayer('ASSO2'); |
|
301 | - } |
|
302 | - if ($level1type !== 'SOUR') { |
|
303 | - FunctionsEdit::printAddLayer('RESN'); |
|
304 | - } |
|
290 | + if ($level1type !== 'OBJE') { |
|
291 | + FunctionsEdit::printAddLayer('OBJE'); |
|
305 | 292 | } |
306 | - break; |
|
307 | - default: |
|
308 | - // Other types of record do not have these lower-level records |
|
309 | - break; |
|
293 | + FunctionsEdit::printAddLayer('NOTE'); |
|
294 | + FunctionsEdit::printAddLayer('SHARED_NOTE', 2, $level1type); |
|
295 | + if ($level1type !== 'ASSO' && $level1type !== 'NOTE' && $level1type !== 'SOUR') { |
|
296 | + FunctionsEdit::printAddLayer('ASSO'); |
|
297 | + } |
|
298 | + // allow to add godfather and godmother for CHR fact or best man and bridesmaid for MARR fact in one window |
|
299 | + if (in_array($level1type, Config::twoAssociates())) { |
|
300 | + FunctionsEdit::printAddLayer('ASSO2'); |
|
301 | + } |
|
302 | + if ($level1type !== 'SOUR') { |
|
303 | + FunctionsEdit::printAddLayer('RESN'); |
|
304 | + } |
|
305 | + } |
|
306 | + break; |
|
307 | + default: |
|
308 | + // Other types of record do not have these lower-level records |
|
309 | + break; |
|
310 | 310 | } |
311 | 311 | |
312 | 312 | ?> |
@@ -2089,15 +2089,15 @@ discard block |
||
2089 | 2089 | <b> |
2090 | 2090 | <?php |
2091 | 2091 | switch ($father->getSex()) { |
2092 | - case 'M': |
|
2093 | - echo I18N::translate('husband'); |
|
2094 | - break; |
|
2095 | - case 'F': |
|
2096 | - echo I18N::translate('wife'); |
|
2097 | - break; |
|
2098 | - default: |
|
2099 | - echo I18N::translate('spouse'); |
|
2100 | - break; |
|
2092 | + case 'M': |
|
2093 | + echo I18N::translate('husband'); |
|
2094 | + break; |
|
2095 | + case 'F': |
|
2096 | + echo I18N::translate('wife'); |
|
2097 | + break; |
|
2098 | + default: |
|
2099 | + echo I18N::translate('spouse'); |
|
2100 | + break; |
|
2101 | 2101 | } |
2102 | 2102 | ?> |
2103 | 2103 | </b> |
@@ -2128,15 +2128,15 @@ discard block |
||
2128 | 2128 | <b> |
2129 | 2129 | <?php |
2130 | 2130 | switch ($mother->getSex()) { |
2131 | - case 'M': |
|
2132 | - echo I18N::translate('husband'); |
|
2133 | - break; |
|
2134 | - case 'F': |
|
2135 | - echo I18N::translate('wife'); |
|
2136 | - break; |
|
2137 | - default: |
|
2138 | - echo I18N::translate('spouse'); |
|
2139 | - break; |
|
2131 | + case 'M': |
|
2132 | + echo I18N::translate('husband'); |
|
2133 | + break; |
|
2134 | + case 'F': |
|
2135 | + echo I18N::translate('wife'); |
|
2136 | + break; |
|
2137 | + default: |
|
2138 | + echo I18N::translate('spouse'); |
|
2139 | + break; |
|
2140 | 2140 | } |
2141 | 2141 | ?> |
2142 | 2142 | </b> |
@@ -2169,15 +2169,15 @@ discard block |
||
2169 | 2169 | <b> |
2170 | 2170 | <?php |
2171 | 2171 | switch ($child->getSex()) { |
2172 | - case 'M': |
|
2173 | - echo I18N::translate('son'); |
|
2174 | - break; |
|
2175 | - case 'F': |
|
2176 | - echo I18N::translate('daughter'); |
|
2177 | - break; |
|
2178 | - default: |
|
2179 | - echo I18N::translate('child'); |
|
2180 | - break; |
|
2172 | + case 'M': |
|
2173 | + echo I18N::translate('son'); |
|
2174 | + break; |
|
2175 | + case 'F': |
|
2176 | + echo I18N::translate('daughter'); |
|
2177 | + break; |
|
2178 | + default: |
|
2179 | + echo I18N::translate('child'); |
|
2180 | + break; |
|
2181 | 2181 | } |
2182 | 2182 | ?> |
2183 | 2183 | </b> |
@@ -2561,35 +2561,35 @@ discard block |
||
2561 | 2561 | } |
2562 | 2562 | |
2563 | 2563 | switch ($nextaction) { |
2564 | - case 'add_child_to_family_action': |
|
2565 | - $name_fields = array_merge($name_fields, $surname_tradition->newChildNames($father_name, $mother_name, $gender)); |
|
2566 | - break; |
|
2567 | - case 'add_child_to_individual_action': |
|
2568 | - if ($person->getSex() === 'F') { |
|
2569 | - $name_fields = array_merge($name_fields, $surname_tradition->newChildNames('', $indi_name, $gender)); |
|
2570 | - } else { |
|
2571 | - $name_fields = array_merge($name_fields, $surname_tradition->newChildNames($indi_name, '', $gender)); |
|
2572 | - } |
|
2573 | - break; |
|
2574 | - case 'add_parent_to_individual_action': |
|
2575 | - $name_fields = array_merge($name_fields, $surname_tradition->newParentNames($indi_name, $gender)); |
|
2576 | - break; |
|
2577 | - case 'add_spouse_to_family_action': |
|
2578 | - if ($father) { |
|
2579 | - $name_fields = array_merge($name_fields, $surname_tradition->newSpouseNames($father_name, $gender)); |
|
2580 | - } else { |
|
2581 | - $name_fields = array_merge($name_fields, $surname_tradition->newSpouseNames($mother_name, $gender)); |
|
2582 | - } |
|
2583 | - break; |
|
2584 | - case 'add_spouse_to_individual_action': |
|
2585 | - $name_fields = array_merge($name_fields, $surname_tradition->newSpouseNames($indi_name, $gender)); |
|
2586 | - break; |
|
2587 | - case 'add_unlinked_indi_action': |
|
2588 | - case 'update': |
|
2589 | - if ($surname_tradition->hasSurnames()) { |
|
2590 | - $name_fields['NAME'] = '//'; |
|
2591 | - } |
|
2592 | - break; |
|
2564 | + case 'add_child_to_family_action': |
|
2565 | + $name_fields = array_merge($name_fields, $surname_tradition->newChildNames($father_name, $mother_name, $gender)); |
|
2566 | + break; |
|
2567 | + case 'add_child_to_individual_action': |
|
2568 | + if ($person->getSex() === 'F') { |
|
2569 | + $name_fields = array_merge($name_fields, $surname_tradition->newChildNames('', $indi_name, $gender)); |
|
2570 | + } else { |
|
2571 | + $name_fields = array_merge($name_fields, $surname_tradition->newChildNames($indi_name, '', $gender)); |
|
2572 | + } |
|
2573 | + break; |
|
2574 | + case 'add_parent_to_individual_action': |
|
2575 | + $name_fields = array_merge($name_fields, $surname_tradition->newParentNames($indi_name, $gender)); |
|
2576 | + break; |
|
2577 | + case 'add_spouse_to_family_action': |
|
2578 | + if ($father) { |
|
2579 | + $name_fields = array_merge($name_fields, $surname_tradition->newSpouseNames($father_name, $gender)); |
|
2580 | + } else { |
|
2581 | + $name_fields = array_merge($name_fields, $surname_tradition->newSpouseNames($mother_name, $gender)); |
|
2582 | + } |
|
2583 | + break; |
|
2584 | + case 'add_spouse_to_individual_action': |
|
2585 | + $name_fields = array_merge($name_fields, $surname_tradition->newSpouseNames($indi_name, $gender)); |
|
2586 | + break; |
|
2587 | + case 'add_unlinked_indi_action': |
|
2588 | + case 'update': |
|
2589 | + if ($surname_tradition->hasSurnames()) { |
|
2590 | + $name_fields['NAME'] = '//'; |
|
2591 | + } |
|
2592 | + break; |
|
2593 | 2593 | } |
2594 | 2594 | } |
2595 | 2595 | |
@@ -2609,15 +2609,15 @@ discard block |
||
2609 | 2609 | echo '<table class="facts_table">'; |
2610 | 2610 | |
2611 | 2611 | switch ($nextaction) { |
2612 | - case 'add_child_to_family_action': |
|
2613 | - case 'add_child_to_individual_action': |
|
2614 | - // When adding a new child, specify the pedigree |
|
2615 | - FunctionsEdit::addSimpleTag('0 PEDI'); |
|
2616 | - break; |
|
2617 | - case 'update': |
|
2618 | - // When adding/editing a name, specify the type |
|
2619 | - FunctionsEdit::addSimpleTag('0 TYPE ' . $name_type, '', '', null, $person); |
|
2620 | - break; |
|
2612 | + case 'add_child_to_family_action': |
|
2613 | + case 'add_child_to_individual_action': |
|
2614 | + // When adding a new child, specify the pedigree |
|
2615 | + FunctionsEdit::addSimpleTag('0 PEDI'); |
|
2616 | + break; |
|
2617 | + case 'update': |
|
2618 | + // When adding/editing a name, specify the type |
|
2619 | + FunctionsEdit::addSimpleTag('0 TYPE ' . $name_type, '', '', null, $person); |
|
2620 | + break; |
|
2621 | 2621 | } |
2622 | 2622 | |
2623 | 2623 | // First - new/existing standard name fields |
@@ -26,7 +26,7 @@ discard block |
||
26 | 26 | |
27 | 27 | $action = Filter::post('action', null, Filter::get('action')); |
28 | 28 | |
29 | -$controller = new PageController; |
|
29 | +$controller = new PageController; |
|
30 | 30 | $controller |
31 | 31 | ->restrictAccess(Auth::isEditor($controller->tree())) |
32 | 32 | ->addInlineJavascript('var locale_date_format="' . preg_replace('/[^DMY]/', '', str_replace(['j', 'F'], ['D', 'M'], I18N::dateFormat())) . '";'); |
@@ -339,7 +339,7 @@ discard block |
||
339 | 339 | //////////////////////////////////////////////////////////////////////////////// |
340 | 340 | case 'add': |
341 | 341 | $xref = Filter::get('xref', WT_REGEX_XREF); |
342 | - $fact = Filter::get('fact', WT_REGEX_TAG); |
|
342 | + $fact = Filter::get('fact', WT_REGEX_TAG); |
|
343 | 343 | |
344 | 344 | $record = GedcomRecord::getInstance($xref, $controller->tree()); |
345 | 345 | check_record_access($record); |
@@ -438,7 +438,7 @@ discard block |
||
438 | 438 | |
439 | 439 | $newged = ''; |
440 | 440 | if (!empty($_POST['NAME'])) { |
441 | - $newged .= "\n1 NAME " . $_POST['NAME']; |
|
441 | + $newged .= "\n1 NAME " . $_POST['NAME']; |
|
442 | 442 | $name_facts = ['TYPE', 'NPFX', 'GIVN', 'NICK', 'SPFX', 'SURN', 'NSFX']; |
443 | 443 | foreach ($name_facts as $name_fact) { |
444 | 444 | if (!empty($_POST[$name_fact])) { |
@@ -1192,7 +1192,7 @@ discard block |
||
1192 | 1192 | //////////////////////////////////////////////////////////////////////////////// |
1193 | 1193 | case 'linkspouse': |
1194 | 1194 | $famtag = Filter::get('famtag', 'HUSB|WIFE'); |
1195 | - $xref = Filter::get('xref', WT_REGEX_XREF); |
|
1195 | + $xref = Filter::get('xref', WT_REGEX_XREF); |
|
1196 | 1196 | |
1197 | 1197 | $person = Individual::getInstance($xref, $controller->tree()); |
1198 | 1198 | check_record_access($person); |
@@ -1440,7 +1440,7 @@ discard block |
||
1440 | 1440 | $TITL = Filter::post('TITL'); |
1441 | 1441 | if ($TITL) { |
1442 | 1442 | $newgedrec .= "\n1 TITL " . $TITL; |
1443 | - $_HEB = Filter::post('_HEB'); |
|
1443 | + $_HEB = Filter::post('_HEB'); |
|
1444 | 1444 | if ($_HEB) { |
1445 | 1445 | $newgedrec .= "\n2 _HEB " . $_HEB; |
1446 | 1446 | } |
@@ -1460,7 +1460,7 @@ discard block |
||
1460 | 1460 | $REPO = Filter::post('REPO', WT_REGEX_XREF); |
1461 | 1461 | if ($REPO) { |
1462 | 1462 | $newgedrec .= "\n1 REPO @" . $REPO . '@'; |
1463 | - $CALN = Filter::post('CALN'); |
|
1463 | + $CALN = Filter::post('CALN'); |
|
1464 | 1464 | if ($CALN) { |
1465 | 1465 | $newgedrec .= "\n2 CALN " . $CALN; |
1466 | 1466 | } |
@@ -1734,7 +1734,7 @@ discard block |
||
1734 | 1734 | $REPO_NAME = Filter::post('REPO_NAME'); |
1735 | 1735 | if ($REPO_NAME) { |
1736 | 1736 | $gedrec .= "\n1 NAME " . $REPO_NAME; |
1737 | - $_HEB = Filter::post('_HEB'); |
|
1737 | + $_HEB = Filter::post('_HEB'); |
|
1738 | 1738 | if ($_HEB) { |
1739 | 1739 | $gedrec .= "\n2 _HEB " . $_HEB; |
1740 | 1740 | } |
@@ -1944,7 +1944,7 @@ discard block |
||
1944 | 1944 | //////////////////////////////////////////////////////////////////////////////// |
1945 | 1945 | case 'reorder_children': |
1946 | 1946 | $xref = Filter::post('xref', WT_REGEX_XREF, Filter::get('xref', WT_REGEX_XREF)); |
1947 | - $option = Filter::post('option'); |
|
1947 | + $option = Filter::post('option'); |
|
1948 | 1948 | |
1949 | 1949 | $family = Family::getInstance($xref, $controller->tree()); |
1950 | 1950 | check_record_access($family); |
@@ -2342,7 +2342,7 @@ discard block |
||
2342 | 2342 | //////////////////////////////////////////////////////////////////////////////// |
2343 | 2343 | case 'reorder_fams': |
2344 | 2344 | $xref = Filter::post('xref', WT_REGEX_XREF, Filter::get('xref', WT_REGEX_XREF)); |
2345 | - $option = Filter::post('option'); |
|
2345 | + $option = Filter::post('option'); |
|
2346 | 2346 | |
2347 | 2347 | $person = Individual::getInstance($xref, $controller->tree()); |
2348 | 2348 | check_record_access($person); |
@@ -2460,7 +2460,7 @@ discard block |
||
2460 | 2460 | '<div class="form-group row"><label class="col-sm-3 col-form-label" for="keep_chan">' . |
2461 | 2461 | I18N::translate('Last change') . |
2462 | 2462 | '</label><div class="col-sm-9">' . |
2463 | - Bootstrap4::checkbox(I18N::translate('Keep the existing “last change” information'), true, ['name' => 'keep_chan', 'checked' => (bool)$controller->tree()->getPreference('NO_UPDATE_CHAN')]) . |
|
2463 | + Bootstrap4::checkbox(I18N::translate('Keep the existing “last change” information'), true, ['name' => 'keep_chan', 'checked' => (bool) $controller->tree()->getPreference('NO_UPDATE_CHAN')]) . |
|
2464 | 2464 | $details . |
2465 | 2465 | '</div></div>'; |
2466 | 2466 | } else { |
@@ -17,9 +17,7 @@ |
||
17 | 17 | |
18 | 18 | use Fisharebest\Webtrees\Controller\PageController; |
19 | 19 | use Fisharebest\Webtrees\Functions\Functions; |
20 | -use Fisharebest\Webtrees\Functions\FunctionsDb; |
|
21 | 20 | use Fisharebest\Webtrees\Functions\FunctionsEdit; |
22 | -use Fisharebest\Webtrees\Functions\FunctionsImport; |
|
23 | 21 | use Fisharebest\Webtrees\Functions\FunctionsPrint; |
24 | 22 | use Fisharebest\Webtrees\Query\QueryMedia; |
25 | 23 |
@@ -176,7 +176,8 @@ discard block |
||
176 | 176 | <div class="editfacts"> |
177 | 177 | <?php if ($fact->getTag() === 'FILE' && $fact->getParent() instanceof Media): ?> |
178 | 178 | <?= FontAwesome::linkIcon('edit', I18N::translate('Edit'), ['class' => 'btn btn-link', 'href' => 'edit_interface.php?action=media-edit&xref=' . $parent->getXref() . '&fact_id=' . $fact->getFactId() . '&ged=' . $parent->getTree()->getNameHtml()]) ?> |
179 | - <?php else: ?> |
|
179 | + <?php else { |
|
180 | + : ?> |
|
180 | 181 | <?= FontAwesome::linkIcon('edit', I18N::translate('Edit'), ['class' => 'btn btn-link', 'href' => 'edit_interface.php?action=edit&xref=' . $parent->getXref() . '&fact_id=' . $fact->getFactId() . '&ged=' . $parent->getTree()->getNameHtml()]) ?> |
181 | 182 | <?= FontAwesome::linkIcon('copy', I18N::translate('Copy'), ['class' => 'btn btn-link', 'href' => '#', 'onclick' => 'return copy_fact("' . $parent->getXref() . '", "' . $fact->getFactId() . '");']) ?> |
182 | 183 | <?= FontAwesome::linkIcon('delete', I18N::translate('Delete'), ['class' => 'btn btn-link', 'href' => '#', 'onclick' => 'return delete_fact("' . I18N::translate('Are you sure you want to delete this fact?') . '", "' . $parent->getXref() . '", "' . $fact->getFactId() . '");']) ?> |
@@ -185,6 +186,7 @@ discard block |
||
185 | 186 | <?php |
186 | 187 | } else { |
187 | 188 | echo $label; |
189 | +} |
|
188 | 190 | } |
189 | 191 | |
190 | 192 | switch ($fact->getTag()) { |
@@ -95,7 +95,7 @@ discard block |
||
95 | 95 | |
96 | 96 | // Create a media object, and return parameters needed by Select2 |
97 | 97 | header('Content-type: application/json'); |
98 | - $filename = 'eek.jpg'; |
|
98 | + $filename = 'eek.jpg'; |
|
99 | 99 | $auto = Filter::post('auto'); |
100 | 100 | $folder = Filter::post('folder'); |
101 | 101 | $note = Filter::post('note'); |
@@ -142,7 +142,7 @@ discard block |
||
142 | 142 | break; |
143 | 143 | } |
144 | 144 | |
145 | - $gedcom = "0 @new@ OBJE\n1 FILE " . $folder . $file . "\n2 FORM " . $format; |
|
145 | + $gedcom = "0 @new@ OBJE\n1 FILE " . $folder . $file . "\n2 FORM " . $format; |
|
146 | 146 | if ($type !== '') { |
147 | 147 | $gedcom .= "\n3 TYPE " . $type; |
148 | 148 | } |
@@ -112,7 +112,7 @@ discard block |
||
112 | 112 | $hfam = $husb->getPrimaryChildFamily(); |
113 | 113 | if ($hfam) { |
114 | 114 | // remove the|| test for $sosa |
115 | - echo '<td rowspan="2"><img src="' . Theme::theme()->parameter('image-hline') . '"></td><td rowspan="2"><img src="' . Theme::theme()->parameter('image-vline') . '" width="3" height="' . ($pbheight -14 ) . '"></td>'; |
|
115 | + echo '<td rowspan="2"><img src="' . Theme::theme()->parameter('image-hline') . '"></td><td rowspan="2"><img src="' . Theme::theme()->parameter('image-vline') . '" width="3" height="' . ($pbheight - 14) . '"></td>'; |
|
116 | 116 | echo '<td><img class="rap" src="' . Theme::theme()->parameter('image-hline') . '"></td><td>'; |
117 | 117 | // husband’s father |
118 | 118 | if ($hfam && $hfam->getHusband()) { |
@@ -203,7 +203,7 @@ discard block |
||
203 | 203 | $hfam = $wife->getPrimaryChildFamily(); |
204 | 204 | |
205 | 205 | if ($hfam) { |
206 | - echo '<td rowspan="2"><img src="' . Theme::theme()->parameter('image-hline') . '"></td><td rowspan="2"><img src="' . Theme::theme()->parameter('image-vline') . '" width="3" height="' . ($pbheight -14 ) . '"></td>'; |
|
206 | + echo '<td rowspan="2"><img src="' . Theme::theme()->parameter('image-hline') . '"></td><td rowspan="2"><img src="' . Theme::theme()->parameter('image-vline') . '" width="3" height="' . ($pbheight - 14) . '"></td>'; |
|
207 | 207 | echo '<td><img class="rapS" src="' . Theme::theme()->parameter('image-hline') . '"></td><td>'; |
208 | 208 | // wife’s father |
209 | 209 | if ($hfam && $hfam->getHusband()) { |
@@ -289,9 +289,9 @@ discard block |
||
289 | 289 | |
290 | 290 | if ($sosa == 0 && Auth::isEditor($family->getTree())) { |
291 | 291 | echo '<br>'; |
292 | - echo '<a href="edit_interface.php?action=add_child_to_family&ged=' . $family->getTree()->getNameHtml() .'&xref=' . $family->getXref() . '&gender=U">' . I18N::translate('Add a child to this family') . '</a>'; |
|
293 | - echo ' <a class="icon-sex_m_15x15" href="edit_interface.php?action=add_child_to_family&ged=' . $family->getTree()->getNameHtml() .'&xref=' . $family->getXref() . '&gender=M" title="', I18N::translate('son'), '"></a>'; |
|
294 | - echo ' <a class="icon-sex_f_15x15" href="edit_interface.php?action=add_child_to_family&ged=' . $family->getTree()->getNameHtml() .'&xref=' . $family->getXref() . '&gender=F" title="', I18N::translate('daughter'), '"></a>'; |
|
292 | + echo '<a href="edit_interface.php?action=add_child_to_family&ged=' . $family->getTree()->getNameHtml() . '&xref=' . $family->getXref() . '&gender=U">' . I18N::translate('Add a child to this family') . '</a>'; |
|
293 | + echo ' <a class="icon-sex_m_15x15" href="edit_interface.php?action=add_child_to_family&ged=' . $family->getTree()->getNameHtml() . '&xref=' . $family->getXref() . '&gender=M" title="', I18N::translate('son'), '"></a>'; |
|
294 | + echo ' <a class="icon-sex_f_15x15" href="edit_interface.php?action=add_child_to_family&ged=' . $family->getTree()->getNameHtml() . '&xref=' . $family->getXref() . '&gender=F" title="', I18N::translate('daughter'), '"></a>'; |
|
295 | 295 | echo '<br><br>'; |
296 | 296 | } |
297 | 297 | echo '</td>'; |
@@ -346,7 +346,7 @@ discard block |
||
346 | 346 | } |
347 | 347 | |
348 | 348 | if ($f == $maxfam) { |
349 | - echo '<img height="' . ((($bheight / 2)) ) . 'px"'; |
|
349 | + echo '<img height="' . ((($bheight / 2))) . 'px"'; |
|
350 | 350 | } else { |
351 | 351 | echo '<img height="' . $pbheight . 'px"'; |
352 | 352 | } |
@@ -461,7 +461,7 @@ discard block |
||
461 | 461 | if ($kids) { |
462 | 462 | echo '<table cellspacing="0" cellpadding="0" border="0" ><tr>'; |
463 | 463 | if ($kids > 1) { |
464 | - echo '<td rowspan="', $kids, '"><img width="3px" height="', (($bheight) * ($kids -1)), 'px" src="', Theme::theme()->parameter('image-vline'), '"></td>'; |
|
464 | + echo '<td rowspan="', $kids, '"><img width="3px" height="', (($bheight) * ($kids - 1)), 'px" src="', Theme::theme()->parameter('image-vline'), '"></td>'; |
|
465 | 465 | } |
466 | 466 | $ctkids = count($fchildren); |
467 | 467 | $i = 1; |
@@ -117,7 +117,7 @@ discard block |
||
117 | 117 | $h = ($kids - 1) * 4 + $h; |
118 | 118 | } |
119 | 119 | echo '<td class="tdbot">', |
120 | - '<img id="vline_', $child->getXref(), '" src="', Theme::theme()->parameter('image-vline'), '" width="3" height="', $h -4, '"></td>'; |
|
120 | + '<img id="vline_', $child->getXref(), '" src="', Theme::theme()->parameter('image-vline'), '" width="3" height="', $h - 4, '"></td>'; |
|
121 | 121 | } elseif ($i === count($children) - 1) { |
122 | 122 | // Adjust for the first column on left |
123 | 123 | $h = round(((($this->getBoxDimensions()->height) * $kids) + 8) / 2); |
@@ -126,7 +126,7 @@ discard block |
||
126 | 126 | $h = ($kids - 1) * 4 + $h; |
127 | 127 | } |
128 | 128 | echo '<td class="tdtop">', |
129 | - '<img class="bvertline" width="3" id="vline_', $child->getXref(), '" src="', Theme::theme()->parameter('image-vline'), '" height="', $h -2, '"></td>'; |
|
129 | + '<img class="bvertline" width="3" id="vline_', $child->getXref(), '" src="', Theme::theme()->parameter('image-vline'), '" height="', $h - 2, '"></td>'; |
|
130 | 130 | } else { |
131 | 131 | echo '<td class="tdbot"style="background: url(', Theme::theme()->parameter('image-vline'), ');">', |
132 | 132 | '<img class="spacer" width="3" src="', Theme::theme()->parameter('image-spacer'), '"></td>'; |
@@ -276,7 +276,7 @@ discard block |
||
276 | 276 | } |
277 | 277 | } |
278 | 278 | echo '</tr><tr>', |
279 | - '<td class="tdtop"><img class="pvline" src="', Theme::theme()->parameter('image-vline'), '" width="3" height="', $lh-2, '"></td>', |
|
279 | + '<td class="tdtop"><img class="pvline" src="', Theme::theme()->parameter('image-vline'), '" width="3" height="', $lh - 2, '"></td>', |
|
280 | 280 | '<td><img class="line4" src="', Theme::theme()->parameter('image-hline'), '" height="3"></td>', |
281 | 281 | '<td>'; |
282 | 282 | //-- print the mother box |