Findagrave Media Link Import
Findagrave Media Link Import | |||
---|---|---|---|
Summary | Adds Find A Grave external media links to burials with Source/Citations that reference a Find A Grave Memorial. | ||
Validation | Admin application not validated. | ||
Mod Updated | {{{mod_last_update}}} | ||
Download link | for
| ||
Download stats | |||
Author(s) | Wendel Voigt | ||
Homepage | Findagrave Media Link Import | ||
Mod Support | TNG Forums | ||
Contact Developer | TNG Forums | ||
Latest Mod | 9.0.0.0 for TNG V9 and up | ||
Min TNG V | 9.0.0 | ||
Max TNG V | 10.0.0+ | ||
Files modified | |||
Related Mods | |||
Notes | Based on Linking_To_Find_A_Grave |
Introduction
Inspired by Linking_To_Find_A_Grave but not inspired enough to individually add all the links by hand, I wanted an easier way to add Find A Grave external media links to burial events. Since I was already adding Find A Grave Source/Citations to individuals, I focused on using those citations to automatically add the Find A Grave links. This mod does the following:
- Adds a custom 'Find A Grave' media type if it does not already exist
- Searches through all the burial events looking for Source/Citations that contain the text 'findagrave.com' (This can be in the Source or the Citation and is not case sensitive.)
- For each of those found, look for a Memorial number in the Citation. If found, go to findagrave.com, get the page, and extract the title. Then either add or update the media with the information and make sure it is linked to the person's burial event.
To use this mod, go to 'Administration', then 'Import/Export', then 'Secondary Processes' tab and finally click the 'Find-A-Grave Import' button.
Memorial Numbers
The Memorial numbers recognized automatically in the Citation can take the following forms:
- GRid=<digits> // as found in a Find A Grave URLs
- Memorial <number> <digits> // all case insensitive with zero or more spaces between the parts
where:
- <digits> = one or more numbers 0 to 9. This is assumed to be the Find A Grave memorial number.
- <number> = #, number, nummber, nr, nr., nbr, nbr., no, no., or blank/nothing/empty. Case Insensitive.
Examples of recognized Memorial Numbers:
- http://www.findagrave.com/cgi-bin/fg.cgi?page=gr&GRid=122620107
- Memorial #122620107
- Memorial 122620107
- Memorial No. 122620107
- memorial no. 122620107
- MeMoRiAl#122620107
- Memorial 122620107
- Memorial Nbr 122620107
- memorial Number122620107
and remember, either in the Source or in the Citation the keyword 'findagrave.com' (case insensitive) needs to be found. Examples include:
- Findagrave.com
- FindAGrave.com
- www.FINDAGRAVE.com
- http://www.findagrave.com
- http://www.findagrave.com/cgi-bin/fg.cgi?page=gr&GRid=122620107
Requirements
- A working TNG installation. This mod was initially tested on TNG Versions 9.2.2 and 10.0.3.
- An installed current version of the Mod Manager.
Revision History
Version | Date | Contents |
---|---|---|
V9.0.0.0 | xx September 2014 | Original version findagrave_import_v9.0.0.0.zip |
Automated Installation
For TNG V9 and above
TNG version: | ≥ 9.0 |
- Download the appropriate zip file from the Mod Summary in the upper right hand corner
- After downloading the zip file, unzip it into your mods folder
- Follow the normal automated installation for Mod Manager, as shown in the example Mod Manager - Installing Config Files to install the living_flag_backup.cfg.
Upgrade to new version
- In the Mod Manager, uninstall the Mod
- Install the new version of the mod using the Automated Install procedure
Visual of mod
A typical burial field on a person's page before the mod.
The same burial field on a person's page after the Find A Grave media has been added.
The addition of the 'Find-A-Grave Import' button on the Import/Export >> Secondary Processes menu.
An example list of the new Find A Grave media imported by the mod. Note the use of the Collection name to narrow down the list of media displayed.
Custimization
Note the items below already have the default values shown included in the mod. No changes are automatically made to English/cust_text.php or English-UTF8/cust_text.php. But if you want to make changes to the behavior of the mod or to the language, you can manually add these to your customconfig.php file or if you prefer, your language/<language>/cust_text.php file. You only need to add entries that you want to change.
MediaType Definition
$text['FAG_type_ID'] = 'findagrave';
$text['FAG_type_display'] = 'Find A Grave';
$text['FAG_type_path'] = 'findagrave';
$text['FAG_type_liketype'] = 'photos';
$text['FAG_type_form'] = 'html';
$text['FAG_type_icon'] = 'findagrave.png';
$text['FAG_type_thumb'] = 'findagrave.png';
$text['FAG_type_exportas'] = 'findagrave';
$text['FAG_type_disabled'] = 0;
Various Constants
$text['FAG_search'] = 'FindAGrave.com'; // Primary search value for Source/Citations in burial events - case does not matter
// Only change the following line if findagrave.com changes the individual page url. %s is the Memorial number placeholder.
$text['FAG_url'] = "http://www.findagrave.com/cgi-bin/fg.cgi?page=gr&GRid=%s";
$text['FAG_connecttimeout'] = 5;} // Connection timeout in seconds. Only change if you need longer connection time to findagrave.com.
$text['FAG_timeout'] = 4;} // page timeout in seconds. Only change if you see a lot of timeouts retrieving the Find A Grave information.
Text
$text['FAG_txt_title'] = 'Find A Grave'; // Default title if it can't get the real one from findagrave.com
$text['FAG_txt_look'] = "Examine all burial citations...<br />\n";
$text['FAG_txt_noGRid'] = "<strong>No Find A Grave memorial found in the citation.</strong>";
$text['FAG_txt_exists'] = "Media type '%s'already exists. No need to add.<br />\n";
$text['FAG_txt_insert'] = "Media type addition of '%s' <strong>%s</strong>.<br />\n";
$text['FAG_txt_record'] = "Tree:'%10s' ID:%7s Citation:%7s ";
$text['FAG_txt_FAGdata'] = "GRid:%10s Title:<i>%s</i> ";
$text['FAG_txt_FAGtimeout'] = "GRid:%10s <strong>Website Error %s: %s</strong> ";
$text['FAG_txt_media'] = "mediaID:%s medialinkID:%s ";
$text['FAG_txt_results'] = "%s <strong>%s</strong> ";
$text['FAG_txt_succeeded'] = 'succeeded';
$text['FAG_txt_failed'] = 'failed';
$text['FAG_txt_update_full'] = 'Full update';
$text['FAG_txt_update_part'] = 'Update without title';
$text['FAG_txt_add_full'] = 'Full addition';
$text['FAG_txt_add_part'] = 'Addition without title';
$text['FAG_txt_errors0'] = "had no errors";
$text['FAG_txt_errors1'] = "had trouble with getting website information";
$text['FAG_txt_errors2'] = "had update problems with database";
$text['FAG_txt_errors3'] = $text['FAG_txt_errors1']." and ".$text['FAG_txt_errors2'];
$text['FAG_txt_errsummary'] = "<strong>Summary</strong> Adds:%10s, Updates:%10s, Parital Updates:%10s, Find-A-Grave Errors:%10s, TNG Errors: %10s<br />";
In the event of a problem with your TNG site
- Try using the Mod Manager to remove the mod
- copy your backup admin_secondmenu.php and admin_secondary.php files
Removal of the media is a manual process. But it is not too difficult. To remove the 'Find A Grave' media:
- In administration, go to Media
- Set the Collection to 'Find A Grave'
- You can now click 'Select All' followed by 'Delete Selected' to remove the new media. Repeat for each page of 'Find A Grave' media.
- To remove the 'Find A Grave' media type, simply click on 'Delete' once you set the Collection to 'Find A Grave'
Developer
This mod was developed by Wendel Voigt
Sites using this mod
If you download and install this mod, please add your TNG site to the table below
URL | User | Note | Mod-Version | TNG-Version | User-language |
---|---|---|---|---|---|
VoigtWorld.com | ... | Wendel is the developer of the Findagrave Media Link Import Mod | 9.0.0.0 | 9.2.2 | English |
Related Links
- See also Linking_To_Find_A_Grave
TNG Modules Involved
In TNG V9 and above, this mod modifies the following files:
- admin_secondmenu.php
- admin_secondary.php files