First Single Entry Point approach

First Single Entry Point approach.

Modified a lot of files. Added also centralized session, cookies, headers, and corrected a lot of stuff.