where($where)->find(); return $data; } //查找所有上级 function getParent($uid){ //当前用户 static $arr=[]; //当前用户 $member = getDataFind('user',array('uid'=>$uid)); if ($member['spread_uid'] > 0){ $parent = getDataFind('user',array('uid'=>$member['spread_uid'])); $arr[]= $parent['uid']; getParent($parent['uid']); } return $arr; }