While developing my website, I have error reporting enabled. But every time an error is generated, it gets generated on the top of the page, before the opening tag. This breaks the document sometimes and changes many aspects of the website such as performance and the way in elements are displayed.
Is there any way to collect all of the errors and display them all at the bottom of the page?
Thanks heaps!
You could create your own error handler and collect all the errors into the file, for instance. Or into the array and then show all the errors at the bottom of the page, as you requested.
Here’s how it should go:
And then, you could get the access to all the errors, by category using this:
UPD: To display the errors at the bottom of the page, add this code to the place you want to output the errors: