Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /* Create Database configuration */
- $server = "localhost";
- $username = "root";
- $password = "";
- $database = "Library";
- /* Begin Connection */
- try{
- /* Setup PDO Connection */
- $connection = new PDO("mysql:host=$server;dbname=$database",$username,$password);
- echo " Connected ! ";
- }catch(PDOException $e){
- /* Any connection Errors */
- echo "Error : " . $e->getMessage();
- }
- ?>
Add Comment
Please, Sign In to add comment