List Media

From TNG_Wiki
Jump to navigation Jump to search
Restricted Downloads of List Media are restricted to logged in users. If you do not have a user account on the TNG Wiki use the Request Account link to request a user account Restricted
Caution If you have trouble downloading with Google Chrome, Vivaldi, Brave or other Chromium based browser, try using a right-click and select Open in new Window, then F5, or use another browser such as Firefox


Caution


Ambox notice.png The latest version of this mod uses the guidelines for TNG v12+ cust_text.php files. If you are using TNGv12+, and any cust_text.php file in this mod is marked with a Bad Target error, you need to update your cust_text.php files before you can install this mod. [Show instructions]

If you upgraded to TNGv12+, and did not update your cust_text.php files as instructed in the upgrade readme script, then you must use the TNG Mod Manager to update them. To do so:

  1. Go to Mod Manager, and select its "Recommended Updates" tab.
    (If the "Recommended Updates" tab is not visible, then go to the Mod Manager Options tab, select "Display Settings", and turn on the "Recommended Updates" tab.)
  2. Click the "Update" button in the "Recommended Updates" tab.
    Installed mods do not interfere with the update, and if you already have (or think you may have) run this update, it will not hurt for you to run it again.

[See details in the TNGv12 Change Impacts Article][Hide the instructions]

TNG 14.0
TNG 13.0
TNG 12.0


List Media
Summary When media is added to TNG you have the option to add an owner or source of the media. This mod lists the owners/source and displays the media for that owner/source
Validation The mod is XHTML compliant.Valid-xhtml10.png
Mod Updated 22 Jan 2022
Download link For
TNG 14.0
TNG 13.0
List Media v13.0.0.1
For
TNG 12.0

List Media v12.0.0.0
For
TNG 11.0

List Media v11.0.0.0
From Developers Website:
For
TNG 10.0
TNG 9.0


TNG Forum

TNG 8.0
Download stats See download statistics
Author(s) Steven Willingale
Homepage List Media (This page)
Mod Support TNG Community Forums
Contact Developer TNG Community Forums
Latest Mod 13.0.0.1 for TNG v13 and up.
Min TNG V 8.0.1
Max TNG V 13+
Files modified
listowner.php (new file)
browseowner.php (new file)
listyear.php (new file)
browseyear.php (new file)
cust_text.php
Related Mods
None
Notes
If using multiple languages, please add the details for your other languages. Dutch, French and German included in v11 and up.

Purpose of the Mod

When media is added to TNG you have the option to add an owner or source of the media and the year/date of the media. This info is displayed when you view the media, but is not searchable within TNG.

This adds a page called listowner.php that displays each owner or source with a count for how many items are attributed to that owner. Clicking the link will take you to browseowner.php which displays each media item for that owner or source. Likewise listyear.php displays the dates of each media item, clicking the link takes you to browseyear.php.

Developer

This mod was developed by Steven Willingale. Updated by Russ Strong to work with current versions TNG v11 through TNG v13+

Requirements

  • A working TNG installation.
  • A backup of all affected files (see the list in the summary in the upper right corner of the page)
  • An installed current version of the Mod Manager.

Revision History

Mod Version TNG Version Date Contents
13.0.0.1 13.0 22 Jan 2022 Updated all files for PHP8.0
13.0.0.0 13.0 22 Nov 2020 Updated files for TNG v13.0.0 updated config file for bad target, and updated the browseowner.php and browseyear.php with the version 13 changes that were made in the browsemedia.php file on which those files were based on.
12.0.0.0 12.0 23 Sep 2018 Updated files for TNG v12.0.0 using the new Modmanager optional file tag @ symbol for the optional language files and their correct target location. Reworked the browseowner.php and browseyear.php with the version 12 changes that were made in the browsemedia.php file on which those files were based on.
11.0.0.0 11.0 22 Sep 2018 Updated to work in version 11 with the optimization for mobile devices and correct the drop down menu icons. Included optional Dutch, French, and German text files. Tested in version 12.0.1.
10.0.0.1 10.0 14 Dec 2014 Amended to add new pages to dropdown menus automatically, proved to work with TNG 10.0.3 (but without the optimization for mobile devices)
.9.1.0.0 9.1 10 Feb 2013 Few minor updates, proved to work with TNG 9.1.1
8.1.1 8.1 23 Aug 2010 UTF-8 English custom text added, sort order changed to number of items, then alphabetically
8.1.0 8.1 19 Aug 2010 Changes to write to tng logfile correctly, coded added to handle items that have no attributed source or owner
8.0.1 8.0 14 Aug 2010 Initial Release

Conflicts and Issues

No known conflicts.

Installation

  1. Uninstall and delete previous version of this mod (if installed)
  2. Download the appropriate zip file as shown in the mod summary in the upper right corner of the page.
  3. Extract the file from the downloaded zip file into the mods folder or FTP the extracted file to your mods folder.
  4. Follow the normal automated installation for Mod Manager, as shown in the example Mod Manager - Installing Config Files to install the mod.

In the event of a problem

Uninstalling the mod

If you want to completely Remove (uninstall) this mod and all its tables, you should

  1. click the Uninstall button to uninstall the mod
  2. click the Delete button to delete the config file from the mods folder.

Upgrade

  • Uninstall and eventually Delete the current Mod.
  • Proceed as for an installation with the new Mod.

Custom Text Additions

Note that config file only includes the English language changes, so if you support multiple languages you will need to add these lines to each of your language cust_text.php files with appropriate translations of course. The version 11.0.0.0+ includes optional Dutch, French, and German translations that will install if needed.

Linking this mod to your site

The cfg file contains the new and amended pages needed, but does not create any links to these new pages. You will need to add a link manually in your topmenu.php file. A quick summary of the steps to do this as follows:

1 Create a copy of topmenu.php and keep it safe in case things go wrong.

2 Open topmenu.php in notepad or your web page editing software.

3 Add the following line of code of topmenu.php (there will be a number of similar lines of code already in topmenu.php, so you should be able to work out where to add this new line)

echo "<li><a href=\"{$cms['tngpath']}listowner.php\" class=\"lightlink\">{$text['mediasource']}</a></li>\n";

4 Save the changes to topmenu.php

5 FTP the amended topmenu.php to your webserver, overwriting the exisiting file.

6 If things go wrong, replace with the backup you kept in step 1

7 Repeat steps to add a link to the listyear.php file by changing 'mediasource' to 'mediayear'.

Or you can try creating a new menu and adding this link to it, such as described in the Site Menu Mod article

Coding_Links_in_Pages also gives some tips for adding links to pages

Visualization

See one of the sites listed below.

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
Steven's Genealogy Steven Willingale Mod Developer 10.0.3 10.1.2 EN
R G Strong Family Genealogy Russell Strong Config file co-developer using modified template 4 13.0.0.1 14.0.4 EN, DE, FR, NL
Bastiaanssen Genealogy Jan Bastiaanssen 13.0.0.1 13.1.2 NL, EN, ES
Ionyclaret 12.0.0.0 12.0.2 EN
van Heerden Emile 13.0.0.0 13.0.4 b2 EN
Carl Wayne Gray Genealogies CarlWGray 13.0.0.0 13.0.3 DE/EN/ES/FR
MyMispoche Carltonb 13.0.0.0 13.0.3 EN
van Heerden Emilevh 13.0.0.0 13.0.4 b2 EN
Steven's Genealogy Steven 12.0.0.0 12.0.3 EN
OurLife Family History - McMullen Clan Seanst 13.0.0.0 13.0.3 EN
Genealogy of a Dutch East-Indies Family Rob Severijns Private 13.0.0.1 13.1.1 NL, EN