Created multipage application.

Also refactored some services code.