diff options
| author | fisharebest <fisharebest@gmail.com> | 2013-07-16 22:59:25 +0000 |
|---|---|---|
| committer | fisharebest <fisharebest@gmail.com> | 2013-07-16 22:59:25 +0000 |
| commit | 4ad1d07a184b7b2266ae85e0767413388fc120d1 (patch) | |
| tree | 084faff771e18d47a151a03d0c9871656bd05b03 | |
| parent | a12b4e821fe5e6e35454192b6aad5ed3aa9d8689 (diff) | |
| download | webtrees-4ad1d07a184b7b2266ae85e0767413388fc120d1.tar.gz webtrees-4ad1d07a184b7b2266ae85e0767413388fc120d1.tar.bz2 webtrees-4ad1d07a184b7b2266ae85e0767413388fc120d1.zip | |
#1192731 - w3.org validation errors
| -rw-r--r-- | includes/functions/functions_print.php | 2 | ||||
| -rw-r--r-- | includes/functions/functions_print_facts.php | 6 | ||||
| -rw-r--r-- | modules_v3/personal_facts/module.php | 23 |
3 files changed, 16 insertions, 15 deletions
diff --git a/includes/functions/functions_print.php b/includes/functions/functions_print.php index 0f5b5561b6..9dcd2b7005 100644 --- a/includes/functions/functions_print.php +++ b/includes/functions/functions_print.php @@ -1010,7 +1010,7 @@ function print_add_new_fact($id, $usedfacts, $type) { $newRow = false; echo '<tr><td class="descriptionbox">'; echo WT_I18N::translate('Add from clipboard'), '</td>'; - echo '<td class="optionbox wrap"><form method="get" name="newFromClipboard" action="" onsubmit="return false;">'; + echo '<td class="optionbox wrap"><form method="get" name="newFromClipboard" action="#" onsubmit="return false;">'; echo '<select id="newClipboardFact" name="newClipboardFact">'; } $fact_type=WT_Gedcom_Tag::getLabel($fact['fact']); diff --git a/includes/functions/functions_print_facts.php b/includes/functions/functions_print_facts.php index e5fc3ac5be..17966f6710 100644 --- a/includes/functions/functions_print_facts.php +++ b/includes/functions/functions_print_facts.php @@ -92,17 +92,17 @@ function print_fact(WT_Fact $fact, WT_GedcomRecord $record) { // Event of close relative if (preg_match('/^_[A-Z_]{4,5}_[A-Z0-9]{4}$/', $fact->getTag())) { - $styleadd .= ' rela'; + $styleadd = trim($styleadd . ' rela'); } // Event of close associates if ($fact->getFactId()=='asso') { - $styleadd .= ' rela'; + $styleadd = trim($styleadd . ' rela'); } // historical facts if ($fact->getFactId()=='histo') { - $styleadd .= ' histo'; + $styleadd = trim($styleadd . ' histo'); } // Does this fact have a type? diff --git a/modules_v3/personal_facts/module.php b/modules_v3/personal_facts/module.php index 5f8f65f037..56f40027e3 100644 --- a/modules_v3/personal_facts/module.php +++ b/modules_v3/personal_facts/module.php @@ -114,20 +114,12 @@ class personal_facts_WT_Module extends WT_Module implements WT_Module_Tab { ob_start(); echo '<table class="facts_table">'; - echo '<script>'; - if (!$EXPAND_RELATIVES_EVENTS) { - echo "jQuery('tr.rela').toggle();"; - } - if (!$EXPAND_HISTO_EVENTS) { - echo "jQuery('tr.histo').toggle();"; - } - echo '</script>'; - + echo '<tbody>'; if (!$indifacts) { echo '<tr><td colspan="2" class="facts_value">', WT_I18N::translate('There are no Facts for this individual.'), '</td></tr>'; } - echo '<tr><td colspan="2" class="descriptionbox rela"><input id="checkbox_rela_facts" type="checkbox"'; + echo '<tr><td colspan="2" class="descriptionbox rela"><form action="#"><input id="checkbox_rela_facts" type="checkbox"'; if ($EXPAND_RELATIVES_EVENTS) { echo ' checked="checked"'; } @@ -139,7 +131,7 @@ class personal_facts_WT_Module extends WT_Module implements WT_Module_Tab { } echo ' onclick="jQuery(\'tr.histo\').toggle();"><label for="checkbox_histo">', WT_I18N::translate('Historical facts'), '</label>'; } - echo '</td></tr>'; + echo '</form></td></tr>'; foreach ($indifacts as $fact) { print_fact($fact, $controller->record); @@ -149,8 +141,17 @@ class personal_facts_WT_Module extends WT_Module implements WT_Module_Tab { if ($controller->record->canEdit()) { print_add_new_fact($controller->record->getXref(), $indifacts, 'INDI'); } + echo '</tbody>'; echo '</table>'; + if (!$EXPAND_RELATIVES_EVENTS) { + echo '<script>jQuery("tr.rela").toggle();</script>'; + } + if (!$EXPAND_HISTO_EVENTS) { + echo '<script>jQuery("tr.histo").toggle();</script>'; + } + + return '<div id="'.$this->getName().'_content">'.ob_get_clean().'</div>'; } |
