--> {{array[index].title}} 确定 /* 用户中心 */ function actionUsercenter(){ $userinfo = $this->userinfo; $user = get_model_one(array('uid' => $userinfo['uid']), 'user_profile'); $userinfo=$this->userinfo; $result=get_model_other(array('uid'=>$userinfo['uid']), 'kecheng_kechenguid'); $arr=array(); if($result){ foreach ($result as $k=>$v){ $info=get_model_one(array('id'=>$v['kid']), 'kecheng_kecheng'); $arr[]=array('id'=>$v['kid'],'title'=>$info['title']); /* $info['imgurl']=get_img($info['img']); $info['tiname']=get_onerecord(array('uid'=>$info['adduid']), 'user_profile', 'realname'); $result[$k]['info']=$info; */ } } /* 头像 */ $user['imgurl']=get_img($userinfo['headimgurl']); $msg['status']=1; $msg['user']=$user; $msg['arr']=$arr; echo json_encode($msg); exit; }