#1 xoYu
function show(){$tpl = $this->spArgs("tpl", "green");
$id = $this->spArgs("id");
$guestbook= spClass("guestbook");
$conditions = array('id'=>$id);
$result = $guestbook->find($conditions);
//echo "
name:{$result['name']}
";//echo "
star:{$result['star']}
";//echo "
job:{$result['job']}
";$this->name = $result['name'];
$this->display("{$tpl}/show.html");
}
$this->name = $result['name'];
这一行这样 只能一个一个替换
有没有办法吧存在的字段全部给替换了
就不用一行一行写这么多代码了
2013-01-30 16:06:53