Reputation: 31
I'm creating a cloud storage-like system where users can create files and folders.
The problem is when the files/folders have a special char and/or reserved word in the name.
The original name of the file/folder is being saved in the database but how to overcome the creation of this file/folder in the filesystem, considering all different operating systems?
For instance a filename with /
.
Upvotes: 1
Views: 45
Reputation: 1015
Try use slugify script like this one: https://github.com/kevinlebrun/slug.php
Upvotes: 1