summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--php.html.markdown2
1 files changed, 2 insertions, 0 deletions
diff --git a/php.html.markdown b/php.html.markdown
index 2d4565e0..5cc6a785 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';