News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Building an image gallery from existing attachments

Started by mrsfalcon, February 11, 2019, 03:41:36 PM

Previous topic - Next topic

mrsfalcon

Does anyone have suggestions for building an image gallery from existing attachments? I checked out the gallery and it is nice, but I want to make use of existing images, not upload new ones. Thanks!

Sir Osis of Liver

Attachment file names are hashed without extensions for security reasons, you would have to restore the original file names, then you could post them in a gallery.  In your database, look in _attachments table, it contains filename and file_hash for each attachment.  Copy the attachment files into a new directory, then you can go through the table one file at a time and rename them (do not rename them in /attachments directory, you'll break the post links).  If you're dealing with a lot of files, you could write a script to rename all the files in one go.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

vbgamer45

Not aware of anything.
Do you want a giant list of images or separated by board?
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Advertisement: