Media - Collections
Media - Help: Collections
This article is based on the TNG Collections help file. As far as I can tell, the Collections help file is not linked from any TNG program; just from the navigational links at the top right of the Media and Albums help pages.
What are Collections?
A Collection refers to a logical classification of media items and the folders that media items are stored in. TNG's native collections are Photos, Documents, Headstones, Histories, Videos and Recordings. TNG site administrators may also define additional collections such as "Censuses", "Military", "Homes", and many more.
In TNG, the terms "Collection" and "MediaType" or "Media Type" are essentially synonymous. However, the the term "file type" almost always refers to the format and filename extension of a media file.
A Collection is not restricted to a single file type. For example, .jpg images can be part of any collection, not just Photos or Documents, and the Photos collection does not have to contain only .jpg files
To add a new collection, click on the "Add Collection" button wherever it is visible (for example, on the Media, Add Media and Edit Media screens). A small pop-up form will appear.
The form fields are:
A very short string of characters to be an identifier for this collection. It should not contain spaces or any characters that are not alphanumeric, and ideally it should be 10 characters or less. For example, if you were creating a collection for military records, you might put "military" in this field. This value will not be displayed anywhere, so what you name it doesn't really matter, just as long as it is unique. In general, the Collection ID, as well as the Display Tile, should be plural. (Photos, Histories, Censuses, etc.).
When you export a GEDCOM file that includes media, the file will contain a line for each item indicating what type of media it is. This should be a single word in uppercase. For example, a photo will be exported with the type "PHOTO". If you are creating a new Collection called "Newspapers", you may want to put "NEWSPAPER" in this field.
Note that if you are exporting a GEDCOM to be imported into a genealogy desktop program that only recognizes PHOTO as the media type, you may want to leave the Export As value as PHOTO. See Export Media For Desktop
This is the name that will be displayed wherever collections are listed, and whenever items of this collection are shown. The Display Title can be slightly longer than the Collection ID, but it should still be relatively short. (It is frequently exactly the same as the Collection ID.) Using the same example, you might put "Military Records" in this field. By default, the name you pick will be used in all languages.
If you support multiple languages and want your Display Title to be translated into the languages you support or if you want to add your new collection to the topmenu.php menu, you will need to create an entry in the "cust_text.php" file in each language folder. The key of the $text message should be the collection ID, and the value is the Display Title. In this example, your entry would be
$text['military'] = "Military Records";
Duplicate that line in the cust_text.php file for each language you support, translating only the "Military Records" portion. The key or ID ("military") should not be translated.
The name of the physical folder or directory on your web site where items in this collection will be stored. It should be relatively short, with no spaces and only alphanumeric characters (e.g., "military"). After entering a value, you can click on the "Make Folder" button to try and create it. You should see a message indicating whether the creation was successful or not. If your server did not allow the operation, you will have to use an FTP program or an online file manager to create the folder. It should be created in the same parent folder as the "photos", "documents", "histories" and other collection folder. Make sure the actual name exactly matches the name you put here exactly ("Military" does not match "military").
You may use an existing folder name, especially in sites where (typically because of PC genealogy application constraints), all of your media files are in the same folder.
TNG displays a small icon next to the collection display title in drop-dowm menus. You may create your own icon, or use one of the existing icons in the TNG images folder. Enter the icon filename here. The default folder is the TNG home folder. In TNG V8 and above, it is common to put the icon in the "img" folder, and add that folder name to the filename in this input box, e.g. "img/censuses_icon.gif". But you may put your icon folder anywhere, such as in a site-specific folder, e.g. "mysite/images/censuses_icon.gif".
Note that the built-in media icons are part of a sprite image. You may store your new collection icon in a 20x20 pixel .gif file or, potentially, you may modify the existing TNG sprite image. (See Explanation tray of sprites)
This attribute is available in TNG V8 and above. The thumbnail is shown, for example, on the Person Profile page when a particular media file does not have its own thumnail. The thumbnail file is typically 50x50 pixels, and may be a gif, png, or jpg file. It is expected to be in the "img" folder below your main TNG folder, so typically, the filename is specified without a folder name.
Enter a whole number here to indicate the order in which your custom Collection types will be displayed in the public drop-down menus. Lower numbers appear first.
Same setup as
The Add media and Edit media screens are hard-coded to prompt for additional fields for specific media collections. This "same setup as" field allows you to indicate which of the standard Collection types your new Collection should resemble most, with regard to the layout of those screens. (As of TNG v10.1, the only collection with additional fields is the "headstones" collection, which prompts for a headstone location status and the cemetery where the headstone is located.
If you previously added media types to the mediatypes.php file, you need to removed those lines before you add those media types using the Add Collection, otherwise you will have duplicates in the media menu pull down list. See Media Types - Migrating mods
To edit an existing custom Collection (the standard ones cannot be edited, except in the General Settings), select that Collection from the drop-down list and click on the Edit button. The fields will be as described above.
To delete an existing custom Collection, select that Collection from the drop-down list and click on the Delete button. Neither the physical folder you created, nor any of the items in it, should be deleted.
- Media - Collections
- External Link Collection
- Media - Add New - Collection
- Media - Add New - Collection (Military Ribbons example)
- Getting Media into TNG - A summary of the various techniques.
- Add New Media - Linked to Person or Family - For Editors as well as Administrators
- Media - Add New - Import one multimedia file into TNG. Then link its new Media record to other objects.
- Histories - Creating - Create a new TNG Media record without importing a multimedia file into TNG.
- Media - Import - Import files that are already on the server, but not already defined as Media records.
- Media - Upload - Upload several media files, import them into TNG, and link them (individually or collectively) to other objects.
- Import Media Using GEDCOM - Upload new media files that are referenced inside of a uploaded GEDCOM file.
|TNG version:||≤ 12.3.0|
|TNG version:||≥ 7.0|
|TNG version:||≥ 13.0.0|
Other Useful Articles
- Batch updates of IPTC tags using IrfanView
- Folios on how to handle multi-page documents as if it were a single TNG media object
- Folios - Examples
- Media Functions on how to hook videos into TNG
- Preserving Digital Photos