there’s this stdClass thing in PHP:
<?php
$fakeobj->hi = "o";
echo $fakeobj->hi;
See? Is this php4?
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.
StdClass is present in php 4 and 5. Its not necessarily either – its just a basic class implementation with no methods – a value object. Its used by some functions when they need to generate an object without an explicit user defined class for example
json_decodeor a value object returned by a SOAP request when a class isnt explicitly mapped. Of course a user/developer can also use it.