Is this old way to explain
for PHP oop, if he use var thing?
for example,
<?php
class person {
var name;
}
?>
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.
Yes. The
varkeyword is PHP 4 syntax, deprecated in PHP 5 and no longer used.If you run your script with
E_STRICTerror reporting, it should notify you of this.Use
public,private, orprotectedinstead.See http://www.php.net/manual/en/language.oop5.visibility.php for more information.