bcit-ci / CodeIgniter

Open Source PHP Framework (originally from EllisLab)

Home Page:https://codeigniter.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Codeigniter 3.1.4 and PHP 8.1

yab86 opened this issue · comments

commented

I am getting several error messages while running my script. By far, I am not an expert but I am not able to fix it. It seems like an issue due to PHP 8.1 for me.

Severity: 8192
Message: str_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated
Filename: /myproject/system/core/Output.php
Line Number: 447

Backtrace:
File: /myproject/index.php
Line: 294
Function: require_once

PHP Fatal error: Array and string offset access syntax with curly braces is no longer supported in /myproject/system/libraries/Profiler.php on line 108

Fatal error: Array and string offset access syntax with curly braces is no longer supported in /myproject/system/libraries/Profiler.php on line 108

A PHP Error was encountered

Severity: Compile Error
Message: Array and string offset access syntax with curly braces is no longer supported
Filename: /myproject/system/libraries/Profiler.php
Line Number: 108

#5879

use CI latest version (3.1.13 at the moment)

Maybe it would be a good idea to migrate to CI4 since you are using PHP 8.1