Updated classes to work with the new database design.

The database design is changed to provide a better abstraction and a
clear line between routing & page information. This also enables the
possibility to use the framework for other webrelated software instead
of just this CMS! ^_^