Hello, is there a way to detect the spaces and symbols like @#!~$^&*()+=, etc.. of filename being uploaded and replace it with underscore? any idea? anyone can help? thanks.
$name = preg_replace('/[^\w\-\.]/', '_', $name); PHP: Replaces anything that isn't alphanumeric, or a dot, or a score with an underscore.