encode URI params.

This fixes the error of an malformed URL when a :param has empty spaces.

For example, having /api/:param/ with param="a b" will generate the request
"GET /api/a b  HTTP/1.1" and the target application will read as url the value
"/api/a".
Allow API definition dir to be configured in config.json
Allow you to change the redis db name in the config. Fixes Issue #40
Merge pull request #80 from darkrho/encode-uri-params

encode URI params.
Merge pull request #141 from mtougeron/issue-40

Allow you to change the redis db name in the config. Fixes Issue #40
Add example apiConfigDir to config.json.sample
Tidy up config.json.sample whitespace
Tidy up app.js
Tidy up docs.js and livedocs.js
Merge pull request #137 from rowanhill/configurable-api-config-dir

Allow API definition dir to be configured in config.json
Merge pull request #142 from rowanhill/config-json-tidy

Tidy up config.json.sample whitespace
Merge pull request #143 from rowanhill/app-js-tidy-up

Tidy up app.js
Merge pull request #144 from rowanhill/clientside-js-tidy-up

Tidy up client-side JS