php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #35764 Showing connectiondata if driver are missing
Submitted: 2005-12-21 16:31 UTC Modified: 2005-12-21 16:40 UTC
Votes:1
Avg. Score:1.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:1 (100.0%)
From: thorny at meisterderspiele dot de Assigned:
Status: Not a bug Package: PDO related
PHP Version: 5.1.1 OS: Mandriva Linux 2006
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: thorny at meisterderspiele dot de
New email:
PHP Version: OS:

 

 [2005-12-21 16:31 UTC] thorny at meisterderspiele dot de
Description:
------------
Sorry for me bad English - i hope you can understand me:

I created a PHP without the drivers for PDO-MySQL and tryed to use the PDO-MYSQL. Then an error-message occurs:

Uncaught exception 'PDOException' with message 'could not find driver' in $file:5 Stack trace: #0 $file(5): PDO->__construct('mysql:host=loca...', 'username', 'password') #1 {main} thrown in $file on line 5

It is not really a bug, but it is not to nice, to show the user my MySQL username and password.

Reproduce code:
---------------
$user = "username";
$pass = "password";
$dbh = new PDO('mysql:host=localhost;dbname=test', $user, $pass);

Expected result:
----------------
Error Message like:
Uncaught exception 'PDOException' with message 'could not find driver' in $file:5 Stack trace: #0 $file(5): PDO->__construct('mysql:host=loca...', 'username', 'password') #1 {main} thrown in $file on line 5


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-12-21 16:40 UTC] tony2001@php.net
Error messages are not supposed to be shown to the users, they are for debug purposes only.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 18 14:01:31 2024 UTC