public static function connect($db_name, $host, $user, $password) { if (self::$instance == null) { self::$instance = new self($db_name, $host, $user, $password); } else { die('cannot instantiate two times !'); } return self::$instance; }