Turn off, but log Smarty and PHP errors Topic is solved

General project discussion. NOT for help questions.
Post Reply
replytomk3

Turn off, but log Smarty and PHP errors

Post by replytomk3 »

Hello all. I am searching the forum on how to disable all Smarty and PHP error notification on the frontend of the website, and not finding anything.

.htaccess setting
php_flag display_errors 0

brings website down.

config.php setting
error_reporting(E_ALL ^ E_NOTICE);

has been added, but a PHP error is still displayed
"Warning: filemtime() [function.filemtime]: stat failed for..."

Is that the correct setting for config.php to disable PHP error display?

I would like to know how to disable all Smarty error reporting on my website. Being able to log Smarty and/or PHP errors would be a big bonus.
replytomk3

Re: Turn off, but log Smarty and PHP errors

Post by replytomk3 »

Errors I get is when content was copy-pasted from word with no-no things like page margins in the pasted code, etc.

Once I remove those from my source code, error goes away. But it is unprofessional for my site visitors to see ANY errors.

Text that I copy-pasted into TinyMCE might have contained things like {assign}. CMSMS tries to evaluate that and shows a Smarty error on the front end. I do not want an error to be shown.
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: Turn off, but log Smarty and PHP errors

Post by Dr.CSS »

Don't paste from word or use the word paste box...
replytomk3

Re: Turn off, but log Smarty and PHP errors

Post by replytomk3 »

At this point, I do not know which, if any, of my pages generate Smarty errors. I cannot go thru every single page because there are 400+ and the error is only shown once per page (it may no longer be shown for me).

I also think that it is unprofessional for my site visitors to see PHP or Smarty errors.

I cannot disable display of PHP errors in the .htaccess file.

I do not know how to turn off Smarty errors display.
replytomk3

Re: Turn off, but log Smarty and PHP errors

Post by replytomk3 »

Anyone who knows?
Post Reply

Return to “General Discussion”