php warnings
Hi,
we are getting php warning every time una's cron job runs (it runs every minute). The warning is:
"PHP Warning: Undefined array key "txt_sample_comment_single" in /path-to-una/template/scripts/BxBaseCmtsServices.php on line 384"
How to stop that warnings being sent to our e-mail every minute?
in our php.ini we have: "error_reporting = E_ALL & ~E_DEPRECATED & ~E_STRICT"
Please advice
-
- · Rocco
- ·
Hello add & ~E_WARNING & ~E_NOTICE
-
-
·
LeonidS
-
·
In reply to Rocco
- ·
Hello @Rocco !
This is not a good way to avoid the warning messages. Will check what might be wrong there.
-
·
LeonidS
-
-
- · Mayki
-
·
In reply to LeonidS
- ·
I agree. It is better to check what is wrong then hiding the problem. I hope @LeonidS that you will find out what is wrong.
-
-
- · Wise
- ·
This error indicates a module, usually a third party module, doesn't have a text key defined properly in xxModuleConfig.php.
Suppressing warnings, notices, and deprecated warnings must be done in:
/path_root_site/inc/ in header.inc.php
Find the line about error reporting and change to:
error_reporting(E_ERROR | E_PARSE);
IMHO this should be done on ALL production sites.
It doesn't matter what your php settings are, UNA defines its own in the above file. 😊
-
-
-
·
LeonidS
-
·
In reply to prueba
P
- ·
Hello @prueba !
Yes, but it needs to track it. Please provide me your UNA studio and Cpanel accesses in Messenger, I'll check that.
-
·
LeonidS
-
- · Antonio
- ·
In file BxBaseCmtsServices on line 416:
'subentry_sample' => $CNF['T']['txt_sample_comment_single'] ?? '',
It is the only solution I have found.