Welcome Guest, Not a member yet? Register   Sign In
Deprecated dynamic properties in PHP 8.2
#5

I think a better way is to implement  #[\AllowDynamicProperties]

Easier and much shorter.

In all the above mentioned classes add #[\AllowDynamicProperties] above class xxxxxx {

I give you my changes:


/system/core/URI.php

    #[\AllowDynamicProperties]

    class CI_URI {
   
   
/system/core/Router.php   

    #[\AllowDynamicProperties]

    class CI_Router {
   
   
/system/core/Loader.php 

    #[\AllowDynamicProperties]
   
    class CI_Loader {
   
   
/system/core/Controller.php     
   
    #[\AllowDynamicProperties]

    class CI_Controller {   
   
   
/system/core/DB_driver.php   

    #[\AllowDynamicProperties]

    abstract class CI_DB_driver {
Reply


Messages In This Thread
RE: Deprecated dynamic properties in PHP 8.2 - by ubeljan - 01-19-2023, 09:02 AM



Theme © iAndrew 2016 - Forum software by © MyBB