I would like to write a string to an NSURL which may contain characters such as / or :, which are not supported by the file system. Is there any convenience method to trim these characters? Or maybe a reference containing all illegal characters, so that I can write such a method myself?
I would like to write a string to an NSURL which may contain characters
Share
May be it’s better just to escape them with something like this:
as it stated here?
Or you can just strip ! * ‘ ( ) ; : @ & = + $ , / ? % # [ ] characters, if you wish so.
Look here for a list of reserved characters.