Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
if php-8.2 breaks your webapp
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks
View previous topic :: View next topic  
Author Message
alamahant
Advocate
Advocate


Joined: 23 Mar 2019
Posts: 3935

PostPosted: Fri Nov 15, 2024 10:59 am    Post subject: if php-8.2 breaks your webapp Reply with quote

..try locating the offending .php file in the webapp config directory and prepend
Code:

#[AllowDynamicProperties]

before the class definition(s) like
Code:

#[AllowDynamicProperties] class xyz {.....

Apparently dynamic properties are deprecated in php8-2 and this might mess with your app.
It happend to me with phpldapadmin and I was thus able to remedy the problem.
_________________
:)
Back to top
View user's profile Send private message
Banana
Moderator
Moderator


Joined: 21 May 2004
Posts: 1819
Location: Germany

PostPosted: Fri Nov 15, 2024 1:09 pm    Post subject: Reply with quote

I think you missed a \
See: https://www.php.net/manual/en/class.allowdynamicproperties.php

It is also mentioned in the upgrade to 8.2, but without any references to the above link https://www.php.net/manual/en/migration82.deprecated.php

Never used dynamic properties. Even as I use php for decades now, I find this feature a bad one.
_________________
Forum Guidelines

PFL - Portage file list - find which package a file or command belongs to.
My delta-labs.org snippets do expire
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum