【发布时间】:2014-12-03 00:20:15
【问题描述】:
如果 php 类具有相当于
,有人可以向我解释一下吗Class name
{
Public: <----- this bit
string variable;
int another;
bool athird;
}
或者你必须在php中声明公共变量为
Class name
{
public $variable;
public $another;
public $athird;
}
感谢您的帮助
【问题讨论】:
-
请阅读 PHP 文档并了解自己。