gpt4 book ai didi

php - 错误 : Undefined class constant 'MYSQL_ATTR_USE_BUFFERED_QUERY'

转载 作者:行者123 更新时间:2023-11-29 05:53:17 25 4
gpt4 key购买 nike

目前我收到这种消息,但我不知道如何解决。

命令 php -m 告诉我 PDO 和 pdo_mysql 在那里。

我在 Ubuntu 18.04.1 LTS 上使用 Drupal-8 和 php7.1.20

[Tue Sep 04 09:27:48.210064 2018] [php7:notice] [pid 2183] [client 10.56.99.1:53758] Error: Undefined class constant 'MYSQL_ATTR_USE_BUFFERED_QUERY' in /var/www/dev/web/core/lib/Drupal/Core/Database/Driver/mysql/Connection.php on line 134 #0 /var/www/dev/web/core/lib/Drupal/Core/Database/Database.php(376): Drupal\Core\Database\Driver\mysql\Connection::open(Array)\n#1 /var/www/dev/web/core/lib/Drupal/Core/Database/Database.php(166): Drupal\Core\Database\Database::openConnection('default', 'default')\n#2 [internal function]: Drupal\Core\Database\Database::getConnection('default')\n#3 /var/www/dev/web/core/lib/Drupal/Component/DependencyInjection/PhpArrayContainer.php(79): call_user_func_array('Drupal\\Core\\Dat...', Array)\n#4 /var/www/dev/web/core/lib/Drupal/Component/DependencyInjection/Container.php(171): Drupal\Component\DependencyInjection\PhpArrayContainer->createService(Array, 'database')\n#5 /var/www/dev/web/core/lib/Drupal/Component/DependencyInjection/PhpArrayContainer.php(260): Drupal\Component\DependencyInjection\Container->get('database', 1)\n#6 /var/www/dev/web/core/lib/Drupal/Component/DependencyInjection/PhpArrayContainer.php(62): Drupal\Component\DependencyInjection\PhpArrayContainer->resolveServicesAndParameters(Array)\n#7 /var/www/dev/web/core/lib/Drupal/Component/DependencyInjection/Container.php(171): Drupal\Component\DependencyInjection\PhpArrayContainer->createService(Array, 'cache.container')\n#8 /var/www/dev/web/core/lib/Drupal/Core/DrupalKernel.php(516): Drupal\Component\DependencyInjection\Container->get('cache.container')\n#9 /var/www/dev/web/core/lib/Drupal/Core/DrupalKernel.php(877): Drupal\Core\DrupalKernel->getCachedContainerDefinition()\n#10 /var/www/dev/web/core/lib/Drupal/Core/DrupalKernel.php(469): Drupal\Core\DrupalKernel->initializeContainer()\n#11 /var/www/dev/web/core/lib/Drupal/Core/DrupalKernel.php(665): Drupal\Core\DrupalKernel->boot()\n#12 /var/www/dev/web/index.php(19): Drupal\Core\DrupalKernel->handle(Object(Symfony\Component\HttpFoundation\Request))\n#13 {main}

最佳答案

没有。

apt-get install php-mysql 和一个简单的 service apache2 restart 至少修复了那个错误。

关于php - 错误 : Undefined class constant 'MYSQL_ATTR_USE_BUFFERED_QUERY' ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/52163353/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com