diff options
Diffstat (limited to 'php.html.markdown')
-rw-r--r-- | php.html.markdown | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/php.html.markdown b/php.html.markdown index 52ea2a95..3fcce264 100644 --- a/php.html.markdown +++ b/php.html.markdown @@ -495,7 +495,9 @@ class MyClass } } +// Class constants can always be accessed statically echo MyClass::MY_CONST; // Outputs 'value'; + echo MyClass::$staticVar; // Outputs 'static'; MyClass::myStaticMethod(); // Outputs 'I am static'; |