note 129968 added to pdo.exec
| From: | Anonymous | Date: | Fri, 10 Jan 2025 13:31:50 +0000 |
| Subject: | note 129968 added to pdo.exec | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-221781@lists.php.net to get a copy of this message | ||
<?php
$servername = 'mysql';
$dbname = 'dbname';
$username = 'root'; // Passe den Benutzernamen an
$password = 'password';
try {
$conn = new PDO("mysql:host=$servername;dbname=$dbname", $username, $password);
// set the PDO error mode to exception
$conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
} catch(PDOException $e) {
echo "Connection failed: " . $e->getMessage();
}
?>
----
Server IP: 45.112.84.4
Probable Submitter: 80.90.5.137 (proxied: 193.170.70.27)
----
Manual Page -- https://php.net/manual/en/pdo.exec.php
Edit -- https://main.php.net/note/edit/129968
Del: integrated -- https://main.php.net/note/delete/129968/integrated
Del: useless -- https://main.php.net/note/delete/129968/useless
Del: bad code -- https://main.php.net/note/delete/129968/bad+code
Del: spam -- https://main.php.net/note/delete/129968/spam
Del: non-english -- https://main.php.net/note/delete/129968/non-english
Del: in docs -- https://main.php.net/note/delete/129968/in+docs
Del: other reasons-- https://main.php.net/note/delete/129968
Reject -- https://main.php.net/note/reject/129968
Search -- https://main.php.net/manage/user-notes.php