An unexpected error occurred #" for errors.

3 posts by 2 authors in: Forums > CMS Builder
Last Post: February 11, 2022   (RSS)

By daniel - February 10, 2022

Hi Phil,

It's possible to adjust the errors which display by using the error_reporting() function. To turn off only the deprecated warnings, you can use this:

error_reporting(E_ALL ^ E_DEPRECATED);

Or to suppress all errors/notices/warnings, you can use this:

error_reporting(0);

Note that you will need to include this in your code after the CMSB viewer library has been loaded.

Let me know if you have any other questions!

Thanks,

Daniel
Technical Lead
interactivetools.com

Thanks for the response.  

error_reporting(E_ALL ^ E_DEPRECATED);

Did not suppress the error, but the error_reporting(0) did.

Phil