Routing is now working.

Got routing working, at least in theory (only tested the default page.)

Todo:
-Routing testing on more pages.
-Getting errors working.
-Fixing debug to display nicely.