Difference between revisions of "Relate mod"

From TNG_Wiki
Jump to navigation Jump to search
(2 intermediate revisions by 2 users not shown)
Line 4: Line 4:
 
| mod_validation  =  
 
| mod_validation  =  
 
| mod_last_update = 29 Jun 2016
 
| mod_last_update = 29 Jun 2016
|  download_link  = download_link  =  [http://mossfamilytree.info/download.php?mod=relate&version=11.0.0.2a 11.0.0.2a] for {{Tv110}} <hr />[http://mossfamilytree.info/download.php?mod=relate&version=10.1.3.2a 10.1.3.2a] for {{Tv1013}}
+
|  download_link  = for {{Tv120}}{{Tv110}}<br />[http://mossfamilytree.info/download.php?mod=relate&version=11.0.0.2a 11.0.0.2a]   <hr />[http://mossfamilytree.info/download.php?mod=relate&version=10.1.3.2a 10.1.3.2a] for {{Tv1013}}
 
   
 
   
 
| download_stats  = [http://mossfamilytree.info/downloadstats.php?mod=relate show]
 
| download_stats  = [http://mossfamilytree.info/downloadstats.php?mod=relate show]
Line 13: Line 13:
 
| mod_version    = 11.0.0.2a
 
| mod_version    = 11.0.0.2a
 
| min_TNG_ver    = 10.1
 
| min_TNG_ver    = 10.1
| max_TNG_ver    = 11.0.2
+
| max_TNG_ver    = 12+
 
| TNG_file_list  = getperson.php, familychart.php, customconfig.php
 
| TNG_file_list  = getperson.php, familychart.php, customconfig.php
 
| related_mods    =
 
| related_mods    =
Line 205: Line 205:
 
| [[User:Tngrlkrz|Ron Krzmarzick]]
 
| [[User:Tngrlkrz|Ron Krzmarzick]]
 
| Public & Private
 
| Public & Private
| 11.0.0.2a/11.1.2
+
| 11.0.0.2a/12.0.1
 
| EN,DE,CS,ES
 
| EN,DE,CS,ES
 
|-
 
|-
Line 241: Line 241:
 
| [[User:Ken Roy|Ken Roy]]
 
| [[User:Ken Roy|Ken Roy]]
 
| Public site using template 4.
 
| Public site using template 4.
| 11.0.0.2a / 11.0.2
+
| 11.0.0.2a / 12.0.1
 
| EN, FR
 
| EN, FR
 
|-
 
|-
Line 284: Line 284:
 
| [[User:Hemar|Hendrik Martius]]
 
| [[User:Hemar|Hendrik Martius]]
 
| Half-Public site - Template 12
 
| Half-Public site - Template 12
| 11.0.0.2a / 11.0.2
+
| 11.0.0.2a / 12.0.1
 
| DE, FR, EN, NL
 
| DE, FR, EN, NL
 
|-
 
|-
Line 327: Line 327:
 
* Spanish: [https://es.wikipedia.org/wiki/Anexo:Nomenclatura_de_parentesco_en_espa%C3%B1ol Kinship Nomenclature]
 
* Spanish: [https://es.wikipedia.org/wiki/Anexo:Nomenclatura_de_parentesco_en_espa%C3%B1ol Kinship Nomenclature]
  
 +
[[Category:Mods for TNG v12]]
 
[[Category:Mods for TNG v11]]
 
[[Category:Mods for TNG v11]]
 
[[Category:Mods for TNG v10]]
 
[[Category:Mods for TNG v10]]

Revision as of 13:12, 30 June 2018

Relate mod
Summary A more general verbal description of a relationship. Has support for a number of European languages
Validation
Mod Updated 29 Jun 2016
Download link for
TNG 12.0
TNG 11.0

11.0.0.2a
10.1.3.2a for
TNG 10.1.3
Download stats show
Author(s) Chris Moss
Homepage
Mod Support contact author
Contact Developer author
Latest Mod 11.0.0.2a
Min TNG V 10.1
Max TNG V 12+
Files modified
getperson.php, familychart.php, customconfig.php
Related Mods
Notes
Translations to Danish, French, German, Italian, Norwegian, PortugueseBR, Swedish


This mod puts a row or a button on several pages and charts in TNG which allows a person easily to check the relationship of an individual to an anchor person on the tree. This can include any reachable person in the database, and it is also possible to restrict the tree to purely genetic relationships. It can handle variations in genealogical terminology in 7 European languages.

Install the mod in the usual way using the Mod Manager. From v2 it is important to clear the cache after installation as additions are made to a style sheet.

A graphical representation of the relationship is planned.

Using the mod

collapsed view on individual page

Currently there are links displayed on two pages: the individual page and the family chart. On the individual page the mod appears as a collapsed row after the names in the main grid and On the family chart, the link symbol is shown on both the main spouses of the relationship.

On clicking on the button the next row is opened (or a popup on the family chart) displaying the relationship with the 'anchor'. This is initially the user, if they are logged in and have an entry in the current tree, or by default the first non-living person in the database or any person that an administrator has set as default person for this tree. Example of the Relate mod in action

At the right hand side is a "more" button with a dropdown list with several options, including one to "Make this person the anchor", which will be used in future queries and continue until the end of the session or the anchor being reset (another option). There is also an option to "Show only genetic" relations which restricts the search to blood relations and excludes all marriages and also adoptive and similar relationships.

On family chart, with genetic set

Clicking on the up-arrow or the icon will close the relationship display.

Relationships are shown by default with three relational clauses per sentence. Relations involving "removed" cousins are expressed as for instance, "the daughter of x, who is the cousin of y" or "the cousin of x, who is the father of" as this is less obscure, doesn't represent very different relationships as the same and is also easier to translate into other languages.

A limit of 24 steps for the search is initially assumed which should cover many databases and has so far not yielded too much usage on the server. The search is only done when the user clicks the button, in order not to incur an overhead when it is not needed. The limit can be changed by a parameter in the mod manager. The search is a bidirectional breadth-first search, so that if either end of the search is isolated in the tree it will not waste too much time and the user is informed which end of the search failed. It also means that it doesn't take more than half of those steps in either direction, so the maximum time is equivalent to only 12 steps on a single direction search which the built-in search uses. If you have only a few thousand people in the tree then it may be ok to increase this up to 50 or 80. But if it's 100,000 then the default is more sensible.

An administrator has an extra option of "Make default" below the relationship. This will set the default anchor for guests and logged-in users who don't appear in the current tree. Setting the default to a private or living individual is not permitted if they are not visible to guests, nor to a person limited by a branch. If an admin is looking at the default person this link appears as "Forget default". (Note that the change will not show immediately, only after the next in-line display.) If the admin forgets who has been set, then logging out temporarily will show who is the default anchor.

Examples

Example of a relationship with 5 clauses over 2 sentences

In a Biblical database the relationship of David is given as:

David is the 4 x great nephew of Aaron, the 23 x great grandson of Adam.

although if we restrict the search to genetic relationships one gets an answer with a slightly longer path:

David is the 31 x great grandson of Adam

If there are more than 3 relationships involved in a description, a new sentence is started. e.g. Elector Maximilian Emmanuel of_Bavaria is described in a European royalty database (royal92) as:

Elector Maximilian Emmanuel of_Bavaria is the son-in-law of Margaret Teresa, the sister of King of Spain Charles_II who is the son-in-law of Duke Philippe of_Orleans.
He is the 4 x great grandfather of Louise Marie d'Orleans, the aunt of Queen of England Victoria Hanover.

If there is more than one link of equal length between two people, a "Show more lines" link will be shown and one can see the alternatives. e.g.

For Lady Di:

Diana Frances Spencer is the daughter-in-law of Prince Philip Mountbatten, the 2 x great grandson of Queen of England Victoria Hanover
Diana Frances Spencer is the daughter-in-law of Queen of England Elizabeth_II Alexandra Mary Windsor, the 2 x great granddaughter of Queen of England Victoria Hanover.

though in some cases these may have identical wording–Charles Windsor is described as "the 3 x great grandson of Queen of England Victoria Hanover" twice because of these two routes.

At present there is no way to show more relationships than the minimum possible. This may be relaxed in a future version.

Mod Parameters

The following settings can be made in the Mod Manager After installation, click on Installed >> Edit options. Change a value to what is wanted and click on Update. Settings 3 and 4 are intended for checking purposes and shouldn't normally be left on.

  1. The maximum number of steps in the search. Default is 24. See the discussion above.
  2. The maximum number of relative clauses in the description of relationships. The default is 2. If it is set to 0 each relationship will be in a separate sentence.
  3. Print out the relationship first in coded form. e.g. a great aunt is ipp, where i=sibling, p=parent, also c=child, s=spouse.
  4. Print out the time taken on the server to calculate the relationship. This is an elapsed time which might be an overestimate, as wait time can be included, but will almost certainly not be an underestimate.

The default anchor

This is different for two types of user: for any logged-in user whose name appears in the tree and who has been identified as such by an administrator, their default anchor will always be themself. If they set the anchor on someone else and subsequently choose to forget it, the anchor will return to them.

For anyone else, the default anchor is normally that set up by an administrator for that tree. The administrator should go to the individual they want to set it to, open the relationship display and they will find that the last option is "Make Default". Clicking on this will set the default to that person. Since it is designed for non-logged-in users, it will not allow the default to be set to a living person if the tree settings do not allow anonymous users to see their name. To check the behaviour you will need to log out.

If an administrator has not set a default, the relate mod will generally choose the first non-living person in current tree. This may be suitable, but in one reported tree, the first person in the tree is Adam, who would almost certainly be an unsuitable choice as he would be too far away from most people in the tree.

To change the default anchor, an administrator simply sets it to someone else. If you want to forget it, you will need to go to that person when the "Make default" will appear as "Forget default".

Internally, the default anchors for all trees are stored in the customconfig.php file, which is normally in the main directory but will be placed outside the web space if all the config files are configured that way. Please do not use this to alter the default as it may make it impossible for the mod to make changes.

Handling non-English languages

Translations are currently available in Danish, French, German, Italian, Norwegian, Portuguese and Swedish.

Literal translations of the English relationship terms are misleading in many languages. For example, a 2nd cousin in English is called a 3rd cousin in Nordic languages (counting from the common ancestor). Norwegian also has a separate word for "great grandfather" and generations before this count from there. A different distinction occurs in Portuguese where the word that represents the closeness of a cousin relationship follows the main noun and also must agree with it in gender.

These language-specific changes are represented in the cust_text.php file for each language by a separate array called "$text_settings". The value of this is itself an array of values which allow the mod to represent the name of a relationship according to the rules of that language. This array can be extended in future versions of this mod to take account of the structure of languages not yet handled properly.

The relationships for more distant grandparents, grandchildren etc. are generally represented by a "2 x" notation which is understandable when "2 x great" stands for "great great" but is not so obvious a representation for "second cousin". So the mod uses ordinals for cousin relationships up to a limit defined in the settings array and more distant relations are given as "6th cousin" etc. Relationship terms which don't have wide coverage in other European languages, such as "step-cousin", or "second cousin 3 x removed" are not used.

These rules will not cover every language, so if you find a language which doesn't fit please contact the author. The framework can be extended in a backwards compatible way.

The settings relation

This is only of relevance for people setting up a new translation of relationships for the mod.

If there is any difference in structure for another language, then it is necessary to define values of a $text_settings array. Differences in vocabulary are handled by the normal mechanism. The mechanism is used in English for the ordinal system for cousin (second, third etc), but other examples of when this is needed are:

  1. The numbering of instances of great-grandfather are different. e.g. Norwegian has a word for great grandfather so a 3 x great grandfather is given as 2 x tippoldevar.
  2. The numbering of cousins is different. e.g. in Swedish as well as Norwegian, the count is the number of generations to the common ancestor.
  3. When an ordinal should be placed after the noun as in Portuguese, and maybe should have the appropriate gender ending.

Values may be given for 'cousin', 'parent', 'child', 'nibling' (i.e. nephew or niece) and 'uncleaunt'. The value of the setting is an array with typically 4, 7 or 9 members. e.g. cousin in Norwegian is given as:

$text_setting['cousin'] = array(2,9,2,0,'ord',"-","-");

The first"2" implies an extra definition of cousin (beyond first cousin) which is given as

$text['mcousin2'] = "xxx menning til";

and the definition of "tre" given as:

$text['ord3'] = "tre";

The individual items are:

  1. The number of terms for the basic relationship counting from 1. Use 0 if same as English. In English there is 1 word for cousin, 3 words for father and 2 for uncle. In Norwegian there are 2 words for cousin and 4 for father. In Portuguese there is 1 word for uncle.
  2. The highest ordinal (e.g. second) used.
  3. The difference between the count in the language and in English. In Norwegian a 2nd cousin is a 3-menning (written tremenning) whereas a 3 x great grandfather is 2 x tippoldevar.
  4. Set to 1 if ordinal comes after the noun; otherwise 0.
  5. The name to be used in the text file for ordinals. 'ord' recommended. (see below)
  6. The separator to be used between the number and the noun for males. (e.g. " x " spaces significant)
  7. The separator to be used between the number and the noun for females (in most languages the same as 6).
  8. Male ending for ordinal. (e.g. 'o')
  9. Female ending for ordinal. (e.g. 'a')
  10. Set to 1 if are non-blood relationships should be avoided in uncleaunt and nibling.
  11. Set to 1 to force the use of local terms for this relation. This is used to avoid conflict with the German and Portuguese mod.

New terms use the existing term followed by the maximum number. e.g.

$text['ggfath'] = "oldefar til";
$text['ggfath3'] = "xxx tippoldefar til";

Ordinals are normally given using the word 'ord' followed by the number. e.g. English:

$text['ord2'] = "second ";

whereas in Portuguese it is a prefix:

$text['ord2'] = "bis";

In the case of a prefix do not put a space after the word. But otherwise make sure there is one.

Where there is more than one sequence for a language, then a similar word is recommended: e.g. 'ordt'.

$text['ordt2'] = "segund";

In order to handle languages with different endings for male and female such as Portuguese, the affix for the word, which is all the characters between the number term and the following word, needs to be given twice, the first for male, the second for female. The first pair relate to the normal case in which a number is used, the second for the endings of an ordinal number. A fuller set is as follows:

$text_setting['cousin'] = array(0,6,0,1,'tord',"&ordm; ","&ordf; ","o ","a ");
$text_setting['parent'] = array(2,6,0,0,'ord',"&ordm; ","&ordf; ");

which produces:

second cousin: primo segundo de
third cousin (f): prima terceira de
12th cousin: primo 12º de
2 x great grandfather: triavô de
10 x great grandfather: 10º avô de

Examples in Norwegian are:

2nd cousin: tremenning til
10th cousin: 11-menning til
3 x great grandfather: 2 x tippoldevar til

where the settings are:

$text_setting['cousin'] = array(2,9,2,0,'ord',"-","-");
$text_setting['parent'] = array(4,0,0,0,0,". ",". ");

Setting 10 applies in Swedish and other languages where a person will not be described as a nephew or niece of the spouse of their blood-uncle or aunt. In this case the relationship will be described as, for instance "the niece of the husband of X".

If setting 11 is used, then all terms for the generic relation must be given, followed in each case by a digit giving the generation number. Thus in the case of 'father', one has to define 'fathof1' and 'gfath2', but also 'fil1' and 'stepfath1'. This is to avoid clashes with the other mod.

Acknowledgments

Chris gratefully acknowledges the assistance of Chuck Filteau and Erik Hoppe in testing of the module and Erik Hoppe, Carlos Heuser, Mogens Fenger and Richard Falzini for advice on language issues. All remaining problems are the author's responsibility alone.

TNG User sites using this mod

If you download and install this mod, please add your TNG sites to the table below.

URL User Note Mod-Version/TNG-Version User-language
Moss Family Tree Chris Moss 11.0.0.1c/11.0.1 EN, DE
Chamberlain & Eidenbenz Genealogy Graham Chamberlain Public site 11.0.0.2/11.0.1 EN,NL,FR,DE,ES
Luithlenfamilie Ingo Wagner Not a public site. 11.0.0.2a/11.0.1 EN, DE,FR,NO
Nordic Ancestry Mogens C. Fenger Not a public site. 11.0.0.1/11.0.1 DA, EN
Roots & Relatives Remembered Ron Krzmarzick Public & Private 11.0.0.2a/12.0.1 EN,DE,CS,ES
Slægten Reventlow Christian Ditlev Reventlow Public site. 11.0.0.1/11.0.1 DA, EN, DE
Kemp(e) Family History Andrew Kemp Public site. see User:Kempons EN
Andersson-Hoppe-Sahlin-Thorell Erik Hoppe This mod not public 10.1.3 / 10.1.3 SE, EN, DE
Luithlenfamilie Ingo Wagner Not a Public site 11.0.0.2a / 11.1.2 DE, EN, NO, FR
The Extended Craxford Genealogy Website Alan Craxford Public site using template 4. 10.1.3.1c / 10.1.3 EN
Our Roy and Boucher Family Ken Roy Public site using template 4. 11.0.0.2a / 12.0.1 EN, FR
Brazilian-German genealogies Carlos Heuser Public site 11.0.0.2 / 11.0.1 EN, DE, PT-BR
The Dutton's of Vermont Darrin Dutton Public site 11.0.0.2 / 11.0.2 EN
Bussiere, Robinson, Gingras Website Brian Bussiere Public site 10.1.3.2a / 10.1.3 English, French
Genealogy Family Smit - Kamp Bert Smit Public site 11.0.0.2a / 11.1 NL, EN, DE, DA
Racine d'Alsace J-Louis Valory Public/Private - Template 1 11.0.0.2a - 11.1.1 French
Stamboom Jongman Roel Jongman Public/Private site 10.1.3.2a 10.1.3 NL, DE, EN
Martius Family History Hendrik Martius Half-Public site - Template 12 11.0.0.2a / 12.0.1 DE, FR, EN, NL
The Grahams of Helensburgh Jim Graham Public/Private 11.0.0.2a / 12.0 English

Revision History

Version Date Details
1c for 11.0.0 and 10.1.3 29 Jun 2016 Mainly bug fixes. Normalised ids causing missed targets. Prohibition on defaults in branches removed. French translation added. Corrected several translation errors. Improved the handling of parameters in the mod manager.
2 for 11.0.0 and 10.1.3 2 Aug 2016
  • Replaced links at bottom of row with a single dropdown button on the right, which now appears on all outputs
  • Compatibility with Expand all/Collapse all feature
  • Intermediate names added to some relationships where they were not used
  • Fixed bugs with second half cousin showed as third half cousin and one with generation limit
  • Used case-insensitive comparisons for ids and tree ids

Known problems

  • None current

External References

Useful reference mainly from wikis for genealogical terms in different languages. If you don't speak the language, use the Chrome browser for easier understanding.