PHP Create Local Variables From String [duplicate]
Is there a way to create a variable inside an object from a string? for example: class Whatever { public function createVariables() { $this["variable_name"] = 100; } } I want to dynamically create variables depending on a set of rules that are defined by a child class.
0 upvotes
View original discussion ↗
Comments
Sign in or sign up to comment and upvote.
No comments yet.