Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- //Database connection
- $db = new PDO('mysql:host=localhost;dbname=db;charset=UTF-8', 'user', 'pass');
- try {
- getData($db);
- }
- catch(PDOException $ex) {
- echo "An Error occured!"; //user friendly message
- some_logging_function($ex->getMessage());
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement