public function commit() { if ($this->transTimes > 0) { $result = mysql_query('COMMIT', $this->_linkID); $this->transTimes = 0; if (!$result) { $this->error(); return false; } } return true; }