Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?PHP
- class DBconnect
- {
- private $host = "";
- private $username = "";
- private $password = "";
- private $database = "";
- private $mysqli;
- protected function connect()
- {
- $this->mysqli = new mysqli($this->host, $this->username, $this->password, $this->database) or die(mysql_error());
- return $this->mysqli;
- }
- protected function close()
- {
- $this->mysqli->close();
- }
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement