diff options
Diffstat (limited to 'php/class.php')
-rw-r--r-- | php/class.php | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/php/class.php b/php/class.php new file mode 100644 index 0000000..a2d7875 --- /dev/null +++ b/php/class.php @@ -0,0 +1,25 @@ +<?php + +class Foo { + public $aMemberVar = 'aMemberVar Member Variable'; + public $aFuncName = 'aMemberFunc'; + private $anotherVar = 'xxx'; + + function aMemberFunc() { + return 'Inside `aMemberFunc()`'; + } +} + +$foo = new Foo; + +$s = "asdf "; +$s .= $foo->aMemberFunc(); +$s .= " xxx"; +//$s .= $foo->anotherVar; +$s .= "\n"; +echo $s; + +$x = 2+3; +echo $x; +?> + |