Added templated error pages. Made minor fix to non-templated error pages. Partially fixes WS-77.