<?php
class DBController {
	private $conn = "";
	private $host = "66.70.255.14";
	private $user = "netempire_elsycb";
	private $password = "Tm3Y@1CtWn67";
	private $database = "netempire_elsy";
	function __construct() {
		$conn = $this->connectDB();
		if(!empty($conn)) {
			$this->conn = $conn;			
		}
	}
	function connectDB() {
		$conn = mysqli_connect($this->host,$this->user,$this->password,$this->database);
		$conn-> set_charset("utf8");
		return $conn;
	}
	function executeSelectQuery($query) {
		$result = mysqli_query($this->conn,$query);
		while($row=mysqli_fetch_assoc($result)) {
			$resultset[] = $row;
		}
		if(!empty($resultset))
			return $resultset;
	}
		
}	
?>
