Visibility Operators in PHP

Did you know that visibility operators are REQUIRED for php properties (class variables) and NOT REQUIRED for class methods (functions)?

These are one the many rules that drive me nuts about PHP.

"Class properties must be defined as public, private, or protected. If declared using var, the property will be defined as public."
"Class methods may be defined as public, private, or protected. Methods declared without any explicit visibility keyword are defined as public."

Can you guys (PHP people out there) make the properties public by default (if no visibility operator is used). I used to use “var” but now “var” is obsolete. Have some consistency for God’s sake.

Reference:
http://php.net/manual/en/language.oop5.visibility.php

Let's share thisShare on FacebookShare on Google+Tweet about this on TwitterShare on LinkedIn