Skip to content

Conversation

@guycalledseven
Copy link

Fixes & Optimizations

✅ UTF-8 Transliteration

  • Converts šđčć.png → sdc.png (removes accents & special characters)
  • Uses transliterator_transliterate() (if available) or iconv() fallback.

✅ Handles Filename Length Properly

  • Uses mb_substr() to safely trim multibyte characters.

✅ Removes Double Extensions

  • Prevents filenames like file..png.

✅ Ensures a Safe Filename

  • Removes dangerous characters.
  • Keeps only ASCII, dots, dashes, and underscores.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant