# NSDictionary (CurlHTTPExtensions)

> Declared In:
>   CURLHandle.h

## Category Description

This category adds methods for dealing with HTTP input and output to an NSDictionary.

## Method Types

>   - formatForHTTP
>   - formatForHTTPUsingEncoding:
>   - formatForHTTPUsingEncoding:ordering:

## Instance Methods

### formatForHTTP

`- (NSString *)formatForHTTP`

Convert a dictionary to an HTTP-formatted string with 7-bit ASCII encoding; see formatForHTTPUsingEncoding.

### formatForHTTPUsingEncoding:

`- (NSString *)formatForHTTPUsingEncoding:(NSStringEncoding)inEncoding`

Convert a dictionary to an HTTP-formatted string with the given encoding. Spaces are turned into `+`; other special characters are escaped with `%`; keys and values are output as key=value; in between arguments is `&`.

### formatForHTTPUsingEncoding:ordering:

`- (NSString *)formatForHTTPUsingEncoding:(NSStringEncoding)inEncoding ordering:(NSArray *)inOrdering`

Convert a dictionary to an HTTP-formatted string with the given encoding, as above. The inOrdering parameter specifies the order to place the inputs, for servers that care about this. (Note that keys in the dictionary that aren't in inOrdering will not be included.) If inOrdering is nil, all keys and values will be output in an unspecified order.