Skip to content

Commit

Permalink
Added visibility to static variable declarations
Browse files Browse the repository at this point in the history
  • Loading branch information
rgr4y committed Aug 13, 2013
1 parent bd48b70 commit bbb8c83
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions php.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down

0 comments on commit bbb8c83

Please sign in to comment.