Difference between revisions of "TNG Integration"

From Genwiki

Jump to: navigation, search
Line 49: Line 49:
 
==TNG Modifications==
 
==TNG Modifications==
  
<font color=red><b>!CAUTION!</b> This zip contains a modified</font> ''personlib.php'' <font color=red>and</font> ''getperson.php'' <font color=red>file from TNG version 5.1.4</font><br/>
+
<font color=red><b>!CAUTION!</b> This zip contains a modified TNG </font> ''personlib.php'' <font color=red>and</font> ''getperson.php'' <font color=red>file.</font><br/>
 
'''If you have made any custom modifications to either of these files, do NOT copy these to your TNG directory, you will lose any customizations you have made.'''
 
'''If you have made any custom modifications to either of these files, do NOT copy these to your TNG directory, you will lose any customizations you have made.'''
  
Line 56: Line 56:
 
** link_wiki_strategy_1.php - the wiki link function, see [[TNG_Integration_Search1|TNG Wiki Strategy 1]] for more info
 
** link_wiki_strategy_1.php - the wiki link function, see [[TNG_Integration_Search1|TNG Wiki Strategy 1]] for more info
 
** link_wiki_strategy_2.php - the wiki link function, see [[TNG_Integration_Search2|TNG Wiki Strategy 2]] for more info
 
** link_wiki_strategy_2.php - the wiki link function, see [[TNG_Integration_Search2|TNG Wiki Strategy 2]] for more info
** <font color=red>personlib.php</font> - (this is a modified TNG 5.1.4 file)
+
** <font color=red>version 5.1.4/personlib.php</font> - (this is a modified TNG 5.1.4 file)
** <font color=red>getperson.php</font> - (this is a modified TNG 5.1.4 file)
+
** <font color=red>version 5.1.4getperson.php</font> - (this is a modified TNG 5.1.4 file)
 +
** <font color=red>version 6.0.0/personlib.php</font> - (this is a modified TNG 6.0.0 file)
 +
** <font color=red>version 6.0.0/getperson.php</font> - (this is a modified TNG 6.0.0 file)
  
  
* '''IF you are running v 5.1.4 and you have NOT made any changes to personlib.php then'''
+
* '''IF you are running v 6.0.0 or 5.1.4 and you have NOT made any changes to personlib.php then'''
  
  
# backup your existing TNG v5.1.4 personlib.php and getperson.php files
+
# backup your existing TNG personlib.php and getperson.php files
# download this zip ([[Media:Wiki_Package_Rev_3.1.zip|TNG Wiki Package (Rev 3.1)]])
+
# download this zip ([[Media:Wiki_Package_Rev_4.0.zip|TNG Wiki Package (Rev 4.0)]])
 
# unzip it, examine the contents
 
# unzip it, examine the contents
 
# decide which place search strategy you wish to implement see [[TNG_Integration_Search1|Strategy 1]] or [[TNG_Integration_Search2|Strategy 2]]  
 
# decide which place search strategy you wish to implement see [[TNG_Integration_Search1|Strategy 1]] or [[TNG_Integration_Search2|Strategy 2]]  
Line 71: Line 73:
 
# comment/uncomment the wiki article path style so that it matches your wiki article page paths
 
# comment/uncomment the wiki article path style so that it matches your wiki article page paths
 
#* the article path is the URL style that is used by your wiki.  Two possibilities exist.  Some installation MUST use the "index.php?title=" style URL, others MAY use the path style.  Examine one of your wiki page urls to determine the style you are required to use.
 
#* the article path is the URL style that is used by your wiki.  Two possibilities exist.  Some installation MUST use the "index.php?title=" style URL, others MAY use the path style.  Examine one of your wiki page urls to determine the style you are required to use.
# copy your link_wiki.php, new_doc.gif, personlib.php and getperson.php files to your base TNG directory
+
# copy your link_wiki.php, new_doc.gif, and the applicable personlib.php and getperson.php files to your base TNG directory
 
#* if you are logged in as admin, you should now see grayed icons next to the names
 
#* if you are logged in as admin, you should now see grayed icons next to the names
 
#* follow one of these links and you should end up at your wiki, create page option
 
#* follow one of these links and you should end up at your wiki, create page option
  
  
* '''IF you are NOT running v5.1.4 or you HAVE made changes to either personlib.php or getperson.php then''', you are on your own, however, the modifications are reasonably straight forward.  If you are not completely comfortable doing this sort of update, then try upgrading to TNG v5.1.4 first.  If you are still intent on trying it, here's my best guess:
 
 
 
# backup your existing TNG personlib.php and getperson.php files
 
# download this zip ([[Media:Wiki_Package_Rev_3.1.zip|TNG Wiki Package (Rev 3.1)]])
 
# unzip it, examine the contents
 
# compare the new personlib.php and your existing personlib.php
 
#* modify the 3 appropriate sections of code in your copy of personlib.php, each is marked with a reference to the wiki integration modification
 
# compare the new getperson.php and your existing getperson.php
 
#* modify the appropriate sections of code in your copy of getperson.php, each update is marked with a reference to the wiki integration modification
 
# decide which place search strategy you wish to implement see [[TNG_Integration_Search1|Strategy 1]] or [[TNG_Integration_Search2|Strategy 2]] 
 
# rename your link_wiki_strategyN.php file to link_wiki.php
 
# modify the variables at the top of the link_wiki.php file to match your wiki setup
 
# comment/uncomment the wiki article path style so that it matches your wiki article page paths
 
#* the article path is the URL style that is used by your wiki.  Two possibilities exist.  Some installation MUST use the "index.php?title=" style URL, others MAY use the path style.  Examine one of your wiki page urls to determine the style you are required to use.
 
# copy link_wiki.php, new_doc.gif and your newly updated personlib.php and getperson.php to your base TNG directory
 
#* if you are logged in as admin, you should now see grayed icons next to the names
 
#* follow one of these links and you should end up at your wiki, create page option
 
  
 
* '''In the event of a problem with your TNG site'''
 
* '''In the event of a problem with your TNG site'''

Revision as of 15:30, 24 September 2006

If you are not comfortable with html and php editing, this page may not be for you


GenWiki Overview

This wiki provides additional background on people and places associated with the McFadyen and Parker genealogy research found at genealogy.mcfadyen.ca It has been categorized into two separate sections: People, and Places.

The Genealogical information is managed through a MySql database and includes management for Births, Deaths, Marriages, Photos, Histories, and their relationships. The Genealogy software package is called The Next Generation of Genealogy Sitebuilding © 2001-2006, created by Darrin Lythgoe, Sandy, Utah. (TNG) For more information on this package, follow the link in the previous line of text.

Although the TNG software does not come preconfigured to work specifically with MediaWiki, only a few modifications to the base TNG software are required to achieve a moderate wiki integration. This page includes the information necessary to make those changes.


Revision 1.0 July 17, 2006 - Updated link_wiki.php to include support for both wiki article path styles.
Revision 2.0 July 18, 2006 - Included getperson.php file, missing from initial release, GenWiki for separately installed wiki database.
Revision 3.0 July 24, 2006 - New version where GenWiki tables are installed into the same TNG database. Also includes 2 alternate TNG-GenWiki place link strategies.
Revision 3.1 Aug 3, 2006 - updated strategy 1 file. The Media:link_wiki_strategy_1.zip file. Correction to the url type subsitution.


Resulting GenWiki - TNG features

  1. Within the person pages, an icon ( Doc.gif ) to the right of people's names will be displayed each time a wiki page is found to match the individual's name
  2. If the TNG user is logged in as "admin" then a grayed icon ( New doc.gif ) to the right of all possible wiki link points will be displayed
  3. Within the person pages, all "places" are examined for string matches to the wiki database. Two different customizable strategies have been included
    • Examples of this may be found on the page: Example Page. Check the place "Tiverton" next to "Died" and the wiki link icon Doc.gif next to a couple of the names.
    • The appearance of the icon or place link is automatic if there is a corresponding wiki page.
  4. It is also possible to include links in the notes for pictures and histories, however this is a strictly manual entry (using standard html href=.... language) as in this example - check the History line at the bottom, there is an embedded link.

MediaWiki extensions

Although links to the TNG generated pages can be created using standard wiki html links, a small extension to the MediaWiki language makes this a little easier. A "person" tag was created with the following syntax: <person i=XXX>Description</person> . The TNG person IDs may be determined by examination of the TNG person pages, or hovering you mouse over any TNG person link and monitoring the browser status line.


Requirements

  1. A working TNG installation - see The Next Generation of Genealogy Sitebuilding
    • For improved GenWiki People Name indexing, it is recommended that the TNG option to list Surnames first be used
      • found under Admin - General Settings - Name Order
  2. A working MediaWiki installation - see MediaWiki Download
    • Version 3 requires that MediaWiki is installed into the same TNG database and supports table name prefixes
    • If you prefer to maintain separate GenWiki and TNG databases, you may use version 2, click here
  3. A backup of your TNG files
  4. A backup of your MediaWiki files

TNG Modifications

!CAUTION! This zip contains a modified TNG personlib.php and getperson.php file.
If you have made any custom modifications to either of these files, do NOT copy these to your TNG directory, you will lose any customizations you have made.

  • The zip file contains:
    • new_doc.gif - the grayed down icon for administrators
    • link_wiki_strategy_1.php - the wiki link function, see TNG Wiki Strategy 1 for more info
    • link_wiki_strategy_2.php - the wiki link function, see TNG Wiki Strategy 2 for more info
    • version 5.1.4/personlib.php - (this is a modified TNG 5.1.4 file)
    • version 5.1.4getperson.php - (this is a modified TNG 5.1.4 file)
    • version 6.0.0/personlib.php - (this is a modified TNG 6.0.0 file)
    • version 6.0.0/getperson.php - (this is a modified TNG 6.0.0 file)


  • IF you are running v 6.0.0 or 5.1.4 and you have NOT made any changes to personlib.php then


  1. backup your existing TNG personlib.php and getperson.php files
  2. download this zip (TNG Wiki Package (Rev 4.0))
  3. unzip it, examine the contents
  4. decide which place search strategy you wish to implement see Strategy 1 or Strategy 2
  5. rename your link_wiki_strategy_N.php file to link_wiki.php
  6. modify the variables at the top of the link_wiki.php file to match your wiki setup
  7. comment/uncomment the wiki article path style so that it matches your wiki article page paths
    • the article path is the URL style that is used by your wiki. Two possibilities exist. Some installation MUST use the "index.php?title=" style URL, others MAY use the path style. Examine one of your wiki page urls to determine the style you are required to use.
  8. copy your link_wiki.php, new_doc.gif, and the applicable personlib.php and getperson.php files to your base TNG directory
    • if you are logged in as admin, you should now see grayed icons next to the names
    • follow one of these links and you should end up at your wiki, create page option


  • In the event of a problem with your TNG site
  1. copy your backup personlib.php and getperson.php files to your base TNG directory
    • all should be well now
  2. you may also delete the link_wiki.php and new_doc.gif files


Wiki Language extension

  1. download this zip file with the tag extension code ( MediaWiki Person Tags )
  2. examine the contents
    • there is only one file, persons.php
    • modify the contents;
      • feel free to change the author's name
      • and change to your favourite url
      • and you MUST change the url in the tag where it has "genealogy.mcfadyen.ca" to your url
  3. copy the persons.php file to your wiki site in the directory extensions
    • ensure the file is executable
  4. add the following line at the end of your "LocalSettings.php" file, just before the ?> line
    • include("extensions/persons.php");
  • That's it, the wiki should now understand <person> tags


Suggested Wiki Customizations

  1. use Categories:
    • at the bottom of each Person Page, add a [[Category:People]] tag
    • at the bottom of each Places Page, add a [[Category:Places]] tag
  2. modify your sidebar to include shortcuts to these areas
    • go to page: Mediawiki:sidebar (just enter this in the search box) see this site example
    • edit this page, if you added
      • Category:Places|List of Places
      • Category:People|List of People
    • as entries on this page, all sidebars will change
      • you may have to delete your page cache before you will see it


Support

  1. You're sort of on your own... If you have a specific question, or feel some additional info in the above would help others, feel free to contact me directly. [genealogy at mcfadyen dot ca]
  2. There are lots of changes that could be made, alternate ways to strip the place strings, etc, etc...
    • Please post suggestions, or your own flavour of this mod to the forum or list


Acknowledgments

Sincere thanks to all the TNG users in the TNG list and forums for their continued and dedicated support of Darrin's TNG platform.
A special thanks is extended to

for their perseverance and successful installation of the first GenWiki modifications. Check out their GenWiki extensions to TNG. Roger Navarre also authored the Strategy 2 for the place name parsing.

Personal tools