regexr
regexr copied to clipboard
Fix mysqli error when deploying
When deploying without this fix, the website would show a mysqli connection error on PHP 7.4. Removing unnecessary arguments fixes this issue.
I took a different approach to fix this, and instead added the missing macros in Config.php:
define('DB_PORT', 3306);
define('DB_SOCK', '');
Since Config.php is a config file, this resolves the issue without having to modify the source code, and also provides the ability to connect to the DB over a socket or a different port if needed.