From bbb8c837457eecc95ac3a66db150ed595ff7bb33 Mon Sep 17 00:00:00 2001 From: Rob Vella Date: Mon, 12 Aug 2013 17:34:17 -0700 Subject: Added visibility to static variable declarations --- php.html.markdown | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/php.html.markdown b/php.html.markdown index ce228870..083574ee 100644 --- a/php.html.markdown +++ b/php.html.markdown @@ -440,6 +440,11 @@ class MyClass static $staticVar = 'static'; + // Static variables and their visibility + public static $publicStaticVar = 'publicStatic'; + private static $privateStaticVar = 'privateStatic'; // Accessible within the class only + protected static $protectedStaticVar = 'protectedStatic'; // Accessible from the class and subclasses + // Properties must declare their visibility public $property = 'public'; public $instanceProp; -- cgit v1.2.3