$areaids or msg(); $do->delete($areaids); dmsg('删除成功', '?file=' . $file); break; case 'update': foreach ($post as $v) { $do->update($v); } dmsg('更新成功', '?file=' . $file); break; default: $condition = '1'; if ($kw) { $condition .= " AND (name LIKE '%{$keyword}%' OR domain LIKE '%{$keyword}%')"; } $lists = $do->get_list($condition); include tpl('city'); break; } class city { var $areaid; var $db; var $table; function city($areaid = 0) { global $db, $city; $this->db =& $db; $this->table = $this->db->pre . 'city'; $this->areaid = $areaid; }