public function zanid(){
$contant=$_POST['id'];
for(var $i=0;$i<count($contant);$i++){
$tea=D('Zan');
$where['cid']=$contant[i];
$where['uid']=$_SESSION['nickname'];
$result=$rea->where($where)->select();
if($result){echo true;}else{echo false;}
}
}
其中post过来的是一个数组,我想依次循环出中间的id值,但是一直报错,可以帮忙找找为什么啊???
最佳答案