Added functionality to the session class.

The update is not yet complete as cookie has to be implemented and so
has the User login system.