????

Your IP : 216.73.216.34


Current Path : /home/carpe/public_html/CURSED/
Upload File :
Current File : /home/carpe/public_html/CURSED/database.php

<?php

class Database {
    private $host = "localhost"; 
    private $db_name = "carpe_cursed"; 
    private $username = "carpe_php"; 
    private $password = "onestdestubesonestpasdespots"; 
    private $conn;

    public function getConnection() {
        $this->conn = null;

        try {
            $this->conn = new PDO(
                "mysql:host=" . $this->host . ";dbname=" . $this->db_name,
                $this->username,
                $this->password
            );
            $this->conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); 
        } catch (PDOException $exception) {
            echo "Erreur de connexion : " . $exception->getMessage();
        }

        return $this->conn;
    }
}

?>