【发布时间】:2011-04-12 06:33:55
【问题描述】:
json_encode() 返回一个字符串...
那么下面的代码不应该工作吗?
class TestClass {
private $test = json_encode("test");
}
PHP 输出
Parse error: syntax error, unexpected '(', expecting ',' or ';' in /home/testuser/public_html/test.php on line 10
【问题讨论】: