PHP validator that checks if a given string is a valid/allowed filename in across operating systems