Created
November 18, 2017 10:19
-
-
Save kuredev/a57ba52684f0a3726c1049a987b0d1b5 to your computer and use it in GitHub Desktop.
__get(マジックメソッド)の小さなメモ
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 | |
class Test{ | |
public function __get($name) | |
{ | |
echo $name.PHP_EOL; | |
} | |
} | |
$test = new Test(); | |
$test->hogehoge; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
実行結果