Login | Sign up | Toll-Free: 1-800-752-0455



7 posts by 3 authors in: Forums > CMS Builder
Last Post: January 20, 2014


I have seen that there is a setting in /cmsAdmin/lib/init.php as follows:

  ini_set('display_errors', '1');         //

Is there a setting in the Admin area to turn off display_errors? Or do I need to manually edit the init.php file as follows:

  ini_set('display_errors', '0');         //

Thank you for your help.



Hi Greg, 

No, there's no way to turn off error reporting within the CMS.  So you could either edit the file like you have or create a plugin that does it automatically.

Hope that helps!

Dave Edis - Senior Developer

Hi Greg, 

Try this: 

Plugin Name: Disable Error Reporting
Plugin Description: Disable PHP's error reporting features.
Required System Plugin: Yes

addAction('init_complete', 'disableErrorReporting', null, 0);

function disableErrorReporting(){
  ini_set('display_errors', '0');
  ini_set('display_startup_errors', '0');


Let me know if that works for you.

Dave Edis - Senior Developer

I think you need to remove

Required System Plugin: Yes

So that the plugin can be enabled/disabled as required

<? Larry >
Coding since 1973

Hi Dave,

Thank you for the suggested plugin, I think that will work great. I will be in touch again if there are any problems.



Larry, good point.  

If anyone using this plugin wants to toggle it on and off (such as for debugging purposes) then you'll want to remove the Required System Plugin line.

But if you want it on all the time and want to prevent it from being turned off (such as on a live server where you don't want debug error output) then leave it there.

This applies to any other plugins as well.  If a plugin is critical to the sites operation and you want to make sure it can't be accidentally disabled you can always just add this line to the top:

Required System Plugin: Yes

Hope that helps! Cheers!

Dave Edis - Senior Developer