Jump to content

File names (in particular images)


Recommended Posts

Posted

Since most Operating systems support unicode file names, I'm wondering why PW still sanitizes (image) filenames to [-_.a-z0-9] characters only.
I've used @adrian's Custom Upload Names module before to change file names, but it still depends on @ryan's core Pagefiles->cleanBasename, which strips out all non ascii characters.

HDPI images are often named "image@2x.jpg" and from a copyright perspective "image©2019-company.jpg" would be far more practical (obvious) than hidden exim data. Something like "image-ab&cd.jpg" or "image(v2).jpg" isn't a weird thing either.

Linux, Windows and MacOS can all handle this kind of file names, and offcourse modern browsers too.
Is there any particular reason why this couldn't be implemented as a default in PW?

  • Like 1
  • 1 year later...
Posted

Just out of interest, I recently removed cleanBasename from Custom Upload Names because it was doing weird things with filenames. It's much better without it ?

  • 5 months later...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...