Gedcom Import Mediatype

From TNG_Wiki
Jump to: navigation, search
Gedcom Import Mediatype
Summary Provides a value for the mediatype value (i.e. collection) for all new Media records created by the a Gedcom Import, so that new media files don't get mixed into the existing collections, and you can more easily assign the correct mediatype for them.
Mod Updated 15 May 2018
Download link TNG 12 TNG 11TNG 10.1
Download stats
Author(s) Robin Richmond
Homepage Robin Richmond's Genealogy Database
Mod Support My Mod Support form or TNG Community Forums
Contact Developer My Mod Support form
Latest Mod v10.1.0.3p & v12.0.0.4
Min TNG V 10.0
Max TNG V at least 12.0
Files modified
admin_dataimport.php, admin_gedimport.php, gedimport_misc.php, English/data_help.php, English cust_text.php
Related Mods

Purpose of the Mod

This mod is primarily useful for sites that have a single Media folder, and cannot depend on the folder name to distinguish among the various Collections (i.e. 'Mediatypes') - (Photo, Document, Histories, etc.). With a single Media Folder, the Gedcom Import process can only use the media item "FORM" tag (i.e. the file extension) to distribute media items among Mediatypes. That often can work for, say, HTM and PDF file extensions, but .jpg file extensions are used in several Mediatypes.

This mod doesn't really help figure out which collection a new media item belongs to, but it can isolate the new media files into an otherwise rarely-used collection so that it is easier for the site administrator to find the new files and assign them to the right collection.

Mod Parameters

There are two parameters for admin_dataimport.php, the Gedcom Import Kickoff form:

  1. $mediatypeIDsToChange (defaults to Photos) - New media items that would otherwise be assigned to this Mediatype (or these Mediatypes) will be reassigned to a different Mediatype.
  2. $mediatypeIDForNewMedia (defaults to Videos) - All media items covered by the first parameter will be assigned to this Mediatype so that they are isolated from old media items, and can be found easily for reassignment to the correct Mediatype.

Compatibility And Dependencies

No known mod conflicts or dependencies. This mod is compatible with all the published mods that affect the Gedcom Import process.

Related Mods


  • A working TNG installation.
  • An installed current version of the Mod Manager.
  • You should backup files listed in the panel on the right.


  1. Remove and delete previous version of this mod.
  2. Backup the files updated by this mod. They are listed in the panel at the upper right.
  3. Download the .zip file, and extract its .cfg file to the mods folder.
  4. Follow the normal automated installation for Mod Manager, as shown in the example Mod Manager - Installing Config Files.

In the event of a problem

  1. Try using the Mod Manager Remove capability
  2. Contact me through My Mod Support form.

Visualization of this Mod

Admin>>Import/Export - The Gedcom Import Kickoff Form BEFORE INSTALLATION:

Gedcom import monitor before.png

Admin>>Import/Export - The Gedcom Import Kickoff Form AFTER INSTALLATION:

This visualization shows how three related mods affect the Gedcom Import kickoff form.
Gedcom import mods-after.png

Revision History

Mod Version TNG Version Date Note 12.0+ 15 May 2018 No functional changes; made compatible with TNGv12. 10.1+ 07 Nov 2017 Removed the second line from the cust_text.php target location search string 10.1+ 10 Jun 2017 Modified some fieldnames on the Gedcom Import Kickoff form, and removed dependencies on Show Mod Names (which is now optional) and Blue Info Button (which is now obsolete).|- 9.0-11.0 25 Mar 2016 Additional mod parameters; significantly reworked code 9.0-10.1.3 6 Feb 2016 I hadn't really tested v9 properly, and I updated the mod to use Show Mod Names v2. 9.0-10.1.3 6 Feb 2016 New mod.

Sites using this mod

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

URL User Note Mod-Version TNG-Version User-language
Robin Richmond's Genealogy Database - admin function; not visible. Robin Richmond Mod developer 11.1.1 English