Created
          July 31, 2013 09:53 
        
      - 
      
- 
        Save jrturton/6120821 to your computer and use it in GitHub Desktop. 
    Escaping reserved URL characters
  
        
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | -(NSString*)stringByPercentEscapingReservedURLCharacters | |
| { | |
| NSString *cleanedString = (NSString*)CFBridgingRelease(CFURLCreateStringByAddingPercentEscapes(NULL, (__bridge CFStringRef)self, NULL, (CFStringRef)@"!#$&'()*+,/:;=?@[]", kCFStringEncodingUTF8)); | |
| return cleanedString; | |
| } | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment