Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $dsn = 'mysql:dbname=study;host=localhost';
- $user = 'root';
- $password = 'mysql';
- try {
- $db = new PDO($dsn, $user, $password);
- } catch (PDOException $e) {
- echo 'Connection failed: '. $e->getMessage();
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement