Complete subdir support.

fixes #527
- Fix image upload in backend
- Use config.paths().webroot where necessary