add success and error page