PHP 7.2, php.ini, suPHP ConfigPath, and Perch 3.1.5

  • I have a client who just updated to PHP 7.2.

    We're trying to increase the PHP limits for memory limit, upload size, etc using a php.ini file as that is what the host allows.

    Working from a host help file and a Perch help file* we are trying to make all folders use the php.ini file in the public_html directory.

    * (A2 is not the host we are working with)

    This is the relevant code to add to the .htaccess file (with MYHOME being replaced with the appropriate directory name):

    1. SuPHP_ConfigPath /home/MYHOME/public_html/

    Unfortunately when we update the .htaccess file as directed we get this error when trying to load any page, front-end or admin:

    1. Fatal error: Uncaught Error: Call to undefined function mysqli_report() in /home/strateg9/public_html/admin/core/lib/PerchDB_MySQLi.class.php:17 Stack trace: #0 /home/strateg9/public_html/admin/core/lib/PerchDB.class.php(20): PerchDB_MySQLi->__construct(NULL) #1 /home/strateg9/public_html/admin/core/lib/PerchFactory.class.php(28): PerchDB::fetch() #2 /home/strateg9/public_html/admin/core/inc/auth.php(14): PerchFactory->__construct() #3 /home/strateg9/public_html/admin/core/settings/diagnostics/index.php(6): include('/home/strateg9/...') #4 {main} thrown in /home/strateg9/public_html/admin/core/lib/PerchDB_MySQLi.class.php on line 17

    Diagnostics from Perch are below.

    I'm not sure where to go next, so any pointers could be helpful.


  • kirkroberts

    Changed the title of the thread from “php.ini, suPHP ConfigPath, and Perch 3.1.5” to “PHP 7.2, php.ini, suPHP ConfigPath, and Perch 3.1.5”.
  • drewm

    Approved the thread.
  • Based on that error it seems that the PHP mysql extension is not enabled. You should be able to enable it from the php.ini file.

    Thank you!

    (and sorry, I didn't receive a notification of your reply, hence my slow response)

    The good news is that I was able to enable mysqli using php.ini and Perch seems to work as expected even after updating .htaccess with the suPHP_ConfigPath command.

    The not-so-good news is that I've not yet gotten the suPHP_ConfigPath to work as expected, so even after I increase the PHP settings in php.ini Perch does not "see" them. But perhaps that is a thing for another thread, if needed.

    Thanks for your help!

    Edit: of course, right after I posted this, I got it working. Typical.