I\'m using XAMPP to develop on my localhost. I would like to remove the PHP notices and keep only the warnings. I know this is done through the php.ini
file,
First, make sure you're editing php.ini
, not php-development.ini
or php-production.ini
or anything BUT php.ini
. After that, ensure you restart your Apache server or your changes won't take effect.
Also, check out ini_set for setting ini values at runtime.
As of PHP 7 the regular php.ini file was removed and added with php.ini-production and php.ini-devlopment. In PHP's installation text file they state, "We advise you to use php.ini-production, because we optimized the default settings in this file for performance, and security."
So in short use the php.ini-production
php.ini.development
and php.ini.production
are entirely different from php.ini
.
the problem is that in the php folder the required php.ini
is not marked along with its extension ( .php
). Only php is written.Check the properties of the file 'php
' of "*configuration settings*
" type.it must be .ini
,This is the exact file which manages error reporting.
The PHP.ini file is still there, only it doesn't include the extension .ini, the extension has been removed. You will notice two file name php, one is application file another is configuration setting when you open configuration setting in notepad you will notice that it has ini extension. so the php configuration file is ini file.
My issue is that I was editing the php.ini-production
and overlooked the standard php.ini
file.
I edited the php.ini
file by adding extension=php_odbc.dll
and it fixed the error.
I had this confusion, in my computer, the php.ini file didn't appear with the .ini extension name visible - it was just php , and in the type column, it has the value 'configuration settings'