Finding the original name of an uploaded image

Get help with installation and running phpBB 3.3.x here. Please do not post bug reports, feature requests, or extension related questions here.
ukautoforums
Registered User
Posts: 105
Joined: Thu Mar 02, 2017 10:00 am

Finding the original name of an uploaded image

Post by ukautoforums »

Hi,
Bit of a strange request.

On some of our forum posts members have uploaded pictures.
The pictures display fine on the forum.
I can find the pictures fine in the phpbb_attachments table.
The real file name matches fine.
However the physical filename listed in the phpbb_attachments table doesnt physically exist in the /files/ directory.

There are ~11,000+ in there but some of them that display fine in the forum, that can open in a new tab, that i can download - dont match the physical_filename listed in the phpbb_attachments table.

So my question is - how can I find what they are actually saved as in the /files directory? And why might they be different?

Thanks
ukautoforums
Registered User
Posts: 105
Joined: Thu Mar 02, 2017 10:00 am

Re: Finding the original name of an uploaded image

Post by ukautoforums »

Here is an example:
You do not have the required permissions to view the files attached to this post.
ukautoforums
Registered User
Posts: 105
Joined: Thu Mar 02, 2017 10:00 am

Re: Finding the original name of an uploaded image

Post by ukautoforums »

In the example above, the image is displayed on the forum.
The poster ID matches
original file name matches
I can download the image.
The physical_filename does not match what is physically stored on the server.
User avatar
warmweer
Jr. Extension Validator
Posts: 12204
Joined: Fri Jul 04, 2003 6:34 am
Location: somewhere in the space-time continuum

Re: Finding the original name of an uploaded image

Post by warmweer »

ukautoforums wrote: Wed Feb 12, 2025 11:37 am In the example above, the image is displayed on the forum.
The poster ID matches
original file name matches
I can download the image.
The physical_filename does not match what is physically stored on the server.
Not 100% sure about this but

When uploading as an attachment, the original name is stored in the database, but the uploaded file is renamed (prevents physical name conflicts)
Spelling is freeware, which means you can use it for free.
On the other hand, it is not open source, which means you cannot change it or publish it in a modified form.


Time flies like an arrow, but fruit flies like a banana.
User avatar
thecoalman
Community Team Member
Community Team Member
Posts: 6707
Joined: Wed Dec 22, 2004 3:52 am
Location: Pennsylvania, U.S.A.

Re: Finding the original name of an uploaded image

Post by thecoalman »

The only thing I see is the physical file is not listed in file list.

If you are using FTP use SFTP instead. Servers typically limit file listing to 10K when using FTP. Note this also affects downloading files. if for example you select file folders to download as backup you're only going to get 10K files. This doesn't affect SFTP.
“Results! Why, man, I have gotten a lot of results! I have found several thousand things that won’t work.”

Attributed - Thomas Edison
ukautoforums
Registered User
Posts: 105
Joined: Thu Mar 02, 2017 10:00 am

Re: Finding the original name of an uploaded image

Post by ukautoforums »

thecoalman wrote: Wed Feb 12, 2025 12:39 pm The only thing I see is the physical file is not listed in file list.

If you are using FTP use SFTP instead. Servers typically limit file listing to 10K when using FTP. Note this also affects downloading files. if for example you select file folders to download as backup you're only going to get 10K files. This doesn't affect SFTP.
YES!!!

Thank you - that is it exactly. I wasnt aware of a 10k limit in FTP but when I've switched from FTP the 'missing' files are there.

Return to “[3.3.x] Support Forum”