Last active
December 13, 2015 20:38
-
-
Save satooshi/4971036 to your computer and use it in GitHub Desktop.
PHP code for blog sample.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Satooshi; | |
/** | |
* Short description. | |
* | |
* Long description. | |
*/ | |
class Test | |
{ | |
const CLASS_CONSTANT = 'class constant'; | |
public $prop; | |
public static $staticProp; | |
/** | |
* Constructor. | |
*/ | |
public function __construct() | |
{ | |
$this->prop = 'property'; | |
} | |
/** | |
* Set prop. | |
* | |
* @param string $prop | |
* @return void | |
*/ | |
public function setProp($prop) | |
{ | |
$this->prop = $prop; | |
} | |
/** | |
* Return prop. | |
* | |
* @return string | |
*/ | |
public function getProp() | |
{ | |
return $this->prop; | |
} | |
public function hello() | |
{ | |
// say hello | |
$message = 'hello'; | |
echo $message; | |
// say bye | |
$message = "bye"; | |
echo $bye; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment