Improve image uploader UI

closes #1356
- add button to toggle back to uploader from image-url interface
- put save button next to url-input
- make box-height consistent
- position ui-elements to have equal padding all around to border
Replace cookieSession with session

- changed cookieSession to session
- added session.regenerate for login and logout
- added bookshelf session store
- added session table to database
- added import for databaseVersion 001
- added grunt task test-api
- cleanup of gruntfile to start express when needed only
- moved api tests to functional tests
add test for allowing 4 underscores in markdown
Modified ghostdown markdown extension to allow for 4+ inline underscores

See #1113
- added additional regex rule to replace 4+ underscores with their coded equivalent: &#95;
Merge pull request #1552 from bastilian/markdown-underscores

Modified ghostdown markdown extension to allow for 4+ inline underscores
Merge pull request #1548 from bastilian/improve_image_uploader_ui

Improve image uploader UI
Merge pull request #1247 from sebgie/bookshelf-session

Replace cookieSession with session
Install in sub-directory support.

refs #527
Merge pull request #1523 from halfdan/527-subdir-support
Add postgres build and allow it to fail.

refs #1333
Issue #1556 - Fix meta_title is undefined

Closes #1556 and #1530

This should also fix meta_description in #1530 as well as the other bug that is not
filed for body_class
Fix failing casper tests

no issue
- spam test: changed waitForSelector to waitForText
- feature test: changed waitForRessource to watiForSelector
Merge pull request #1559 from sebgie/failing-tests

Fix failing casper tests
Putting back relative redirects

issue #1523

- also added some comments to indicate the difference between the two custom middleware files.
Merge pull request #1557 from alicoding/issue1556

Issue #1556 - Fix meta_title is undefined
Create the config module, initially used
to standardise getting paths and absolute URLs.  Easy
to extend for other configurations we may need.
Merge pull request #1565 from ErisDS/redirect-fixes

Putting back relative redirects
Merge pull request #1535 from hswolff/create-config-module

Create config module to standardise getting paths and abs URLs
Merge pull request #1555 from halfdan/1333-allowed-failure

Add postgres build and allow it to fail.
Remove cookie from Frontend

closes #1437
closes #1472

- changed cookie to path:'/ghost'
- added conditional CSRF middleware
- added redirects for signup, signin, signout to /ghost/sign*/