added error pages and more