Answer the question
In order to leave comments, you need to log in
How to find out if there are Cyrillic characters in the file name?
Some sites swear at the presence of Cyrillic characters in the file name, is it possible to somehow detect them even before downloading?
Answer the question
In order to leave comments, you need to log in
This is bad practice.
Instead, do this:
1. When saving - name the image container (picture) using a base64 string or ordinal hexadecimal character representation (ID-HEX as String).
2. Real name - write to the database along with the full path to the container.
First, you can rename files on upload.
Secondly, if this does not suit the situation, then you can check the name of the uploaded file with a regular expression: for example ^[0-9\-_A-z]+$
.
To be honest, I didn't really understand the question. Who should upload files and where? And at what stage should they be checked?
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question