#1 zhgzzy
$this->title="网站标题名称";$user = spClass("lib_user");
$this->snum = $user -> findCount();
上面这一部分是每人页面都要显示的内容:一个网站标题和统计会员人数,请问如果放在父类中要如何写???
general.php
class general extends spController
{
}
2010-03-24 16:52:29
2010-03-24 16:52:29
class general extends spController
{
public function __construct()
{
parent::__construct();
$this->title="网站标题名称";
$user = spClass("lib_user");
$this->snum = $user -> findCount();
}
}
2010-03-24 17:20:42
2010-03-26 18:42:01