9dian房间guan理系统(9)
2023-07-17 来源:百合文库
$sql="INSERT INTO `{$table}`({$fieldsStr}) VALUES({$values})";
return self::execute($sql);
}
4. 更新数据
/**
* 更新记录
* @param array $data
* @param string $table
* @param string $where
* @param string $order
* @param string $limit
* @return Ambigous <boolean, unknown, number>
*/
public static function update($data,$table,$where=null,$order=null,$limit=0){
foreach($data as $key=>$val){
$sets.=$key."='".$val."',";
return self::execute($sql);
}
4. 更新数据
/**
* 更新记录
* @param array $data
* @param string $table
* @param string $where
* @param string $order
* @param string $limit
* @return Ambigous <boolean, unknown, number>
*/
public static function update($data,$table,$where=null,$order=null,$limit=0){
foreach($data as $key=>$val){
$sets.=$key."='".$val."',";