Esempio n. 1
0
 public function disconnect()
 {
     try {
         // Alt_Database is assumed disconnected
         $status = TRUE;
         if (is_object($this->_connection)) {
             if ($status = mysqli_close($this->_connection)) {
                 // Clear the connection
                 $this->_connection = NULL;
                 // Clear the instance
                 parent::disconnect();
             }
         }
     } catch (Exception $e) {
         // Alt_Database is probably not disconnected
         $status = !is_object($this->_connection);
     }
     return $status;
 }
Esempio n. 2
0
 public function disconnect()
 {
     // Destroy the PDO object
     $this->_connection = NULL;
     return parent::disconnect();
 }