It looks like you're new here. If you want to get involved, click one of these buttons!
Hello,
With PHP 8.1 I was experiencing a PHP error (see below)
Maybe it is because I was getting data from an old database ?
Anyway, I found a fix :
in file : \fuel\modules\fuel\core\MY_DB_mysqli_driver.php
I added the line (number 189) :
if ($max_length!=NULL)
so that in the end :
if ($type == 'float')
{
if (is_array($max_length))
{
$max_length = current($max_length);
}
if ($max_length!=NULL)
if (strpos($max_length, ',') !== FALSE)
{
$maxes = explode(',', $max_length);
$max_length = 0;
foreach($maxes as $max)
{
$max_length += (int) $max;
}
}
}
Here is the error :
A PHP Error was encountered
Severity: 8192
Message: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated
Filename: core/MY_DB_mysqli_driver.php
Line Number: 189
Comments
I pushed an update to the develop branch for that error:
https://github.com/daylightstudio/FUEL-CMS/commit/c364e8c5307744ad161be0703e26a54d00eb17ec