<?php
// DANIEL CWIKLA
function db_connect() {
    require_once "db_connection.php";

     $db_server = "$db_engine:dbname=$db_name;host=$db_host";

     try {
        $dbh = new PDO($db_server, $db_user, $db_password);
        echo "<p>DB Connected</p>";
        return $dbh; 
     }
     catch(PDOException $e) {
        die("<p>Error</p>");
    }
}
?>


