摘要:
<?php class Car { private function __construct() { echo 'object create'; } private static $_object = null; public static function getInstance() { if ( 阅读全文
posted @ 2019-10-31 22:33
盘思动
阅读(352)
评论(0)
推荐(0)
摘要:
function test3($i){ echo $i . '<br/>'; if ($i >= 0){ $func = __FUNCTION__; // 外面函数名称变了,不用跟着变 $func($i - 1); } echo $i . '<br/>'; } test3(3); 3 2 1 0 -1 -1 0 1 2 3 阅读全文
posted @ 2019-10-31 21:12
盘思动
阅读(141)
评论(0)
推荐(0)
摘要:
Array( [title] => 推荐 [code] => 1) array(3) { [1]=> string(6) "推荐" [3]=> array(2) { // 这里出现很诡异的结果 ["title"]=> string(7) "奇闻2" ["code"]=> int(2) } [4]=> 阅读全文
posted @ 2019-10-31 20:32
盘思动
阅读(191)
评论(0)
推荐(0)