I have a PHP site which (as every other site) has some hidden errors. The question is what should happen when an error occurs?
I see lots of PHP and other sites where in case of an error the page is a bit broken, sometimes even an internal error message is dumped to the page, but usually the site stays partly usable.
The other approach which I follow is to terminate page rendering instantly and show an error message to the user.
Which is the more user friendly approach in your opinion? Let the application continue regardless of the error, so that some part of the page may still be rendered and usable? Or terminate control flow immediately, because it's worse to show a half-baked page to the user and a proper error message should be shown instead?
Update: it's not about 404 pages, rather about those cases, when the page is found, but problems occur during generating it.