public static function __get($value)
does not work, and even if it did, it so happens that I already need the magic __get getter for instance properties in the same class.
This probably is a yes or no question, so, it is possible?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
No, it is not possible.
Quoting the manual page of __get :
In PHP 5.3,
__callStatichas been added ; but there is no__getStaticnor__setStaticyet ; even if the idea of having/coding them often comes back on the php internals@ mailling-list.There is even a Request for Comments: Static classes for PHP
But, still, not implemented (yet ? )