Media - Thumbnails - Moving

From TNG_Wiki
Jump to navigation Jump to search

Media - Thumbnails - Moving

Moving Procedure

The following procedure for moving thumbnails to a subfolder (or subdirectory) of the media collection was provided by Jerome Leibowitz on the TNG user2 list

1) I backed up everything! (just in case)
2) I created new empty subfolders (named thumbnails) in each media folder and subfolder (using my FTP program).
3) I changed the thumbnail path in Admin => Setup => Configuration => General Settings => Media to:


Note that Roger Moffat on the user2 list indicated that he named his folder zzzthumbs so they would sort to the bottom of the list.
Note also that the thumb_ prefix is not necessary if you specify the thumbnail prefix as a subfolder - thumbnails/

4) I went to my server's control panel, and in PhpMyAdmin, I entered the following query:

update tng_media set thumbpath=""

(Actually, I first did it with each media collection, e.g. headstones, documents, using Darrin's suggested query: update tng_media set thumbpath="" where mediatypeID="headstones" and then update tng_media set thumbpath="" where mediatypeID="documents"] This removed all the thumbnail paths from TNG. When I checked to be sure, no thumbnails were linked to any pages.)

5) Then I went to Admin => Media => Thumbnails, clicked on Regenerate thumbnail path names where file does not exist (I did not need to click on "Regenerate existing thumbnails") and then clicked on the "Generate" button.

All thumbnails were then generated and placed in the new folders I had created and included as part of the thumbnail path.

6) After checking with my FTP program to be sure that the thumbnails were regenerated into the thumbnails subfolders, I then deleted all the thumbnails from their original locations.

Everything is now just as it was, except the thumbnails are in separate folders and don't have to be scrolled through when looking for media I uploaded and want to install and then link.

BTW: I do NOT attach media paths when I upload a gedcom. I do all my media attaching in TNG. Although I do not know for sure, once the path is re-set, future imports with media attached should work fine. All one would have to do then in generate the thumbnails as usual (with the new path). Contributed by Jerome Leibowitz on the TNG User2 list on 1 Feb 2009 with SQL update procedure from Darrin

Related Links

Default Photo Path Mod which provides a TNG mod that can be used to moved default photos to a different folder or subfolder.