Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- try{
- $conn = "mysql:host=localhost;dbname=users_dbb";
- $connect = new PDO($conn,"root","");
- // set the PDO error mode to exception
- $connect->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
- echo "you are connected successfully";
- }catch(PDOException $e){
- echo "Connection failed: " . $e->getMessage();
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement