Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $user = "root";
- $password = "simas";
- $db = new PDO('mysql:host=localhost;dbname=guestbook', $user, $password);
- if ($db->getAttribute(PDO::ATTR_DRIVER_NAME) == 'mysql') {
- echo "Running on mysql; doing something mysql specific here\n";
- }
- $c = $db->exec("INSERT INTO page (name, text) VALUES('tmnt', 'mes vezliai')");
- echo $c;
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement