Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $host = "localhost";
- $database = "mydb";
- $username = "root";
- $password = "";
- try {
- $connection = new PDO("mysql:host=$host;dbname=$database;charset=utf8", $username, $password);
- } catch(PDOException $e) {
- echo $e->getMessage(); // message sang error if indi mag connect
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement