Closed daxiyun closed 7 years ago
This is not a bug.
error()
is only for displaying error information associated with the last operation. It don't display misconfigured error message for initialization. You can try catch the new Medoo()
error exception for more information.
Fatal error: Uncaught exception 'Exception' with message 'SQLSTATE[HY000] [1044] Access denied for user 'clipbrd'@'localhost' to database 'clipbrd0'' in /var/www/XXXXXXXXXXXXX/medoo_mysql.php:152 Stack trace: #0 /var/www/XXXXXXXXXXXXX/test.php(23): medoo->__construct(Array) #1 {main} thrown in /var/www/XXXXXXXXXXXXX/medoo_mysql.php on line 152
数据库名字、用户名、密码等配置错误 $conn->error() 无法捕获到错误信息,是500错误