【问题标题】:PHP Warning: PHP Startup: Unable to load dynamic library sqlite3PHP 警告:PHP 启动:无法加载动态库 sqlite3
【发布时间】:2021-10-05 06:33:56
【问题描述】:

我已经在我的系统中安装了 wamp 8.0.10-1,当我运行 wamp 时,error.log 中会生成以下错误。基本上,我想安装 laravel 8,系统兼容性屏幕正在抛出以下消息:

SQLite3 Extension
PHP SQLite3 Extension is required.

错误日志

PHP Warning:  PHP Startup: Unable to load dynamic library 'sqlite3' (tried: D:/wampstack-8.0.10-1/php/ext\\sqlite3 (The specified module could not be found), D:/wampstack-8.0.10-1/php/ext\\php_sqlite3.dll (The specified module could not be found)) in Unknown on line 0
[Tue Oct 05 12:00:27.286105 2021] [mpm_winnt:notice] [pid 21832:tid 628] AH00455: Apache/2.4.48 (Win64) OpenSSL/1.1.1l PHP/8.0.10 configured -- resuming normal operations
[Tue Oct 05 12:00:27.286105 2021] [mpm_winnt:notice] [pid 21832:tid 628] AH00456: Apache Lounge VS16 Server built: Aug 25 2021 12:07:35
[Tue Oct 05 12:00:27.286105 2021] [core:notice] [pid 21832:tid 628] AH00094: Command line: 'D:\\wampstack-8.0.10-1\\apache2\\bin\\httpd.exe -d D:/wampstack-8.0.10-1/apache2 -f D:\\wampstack-8.0.10-1\\apache2\\conf\\httpd.conf'
[Tue Oct 05 12:00:27.286105 2021] [mpm_winnt:notice] [pid 21832:tid 628] AH00418: Parent: Created child process 20640
[Tue Oct 05 12:00:27.509826 2021] [ssl:warn] [pid 20640:tid 584] AH01909: localhost:444:0 server certificate does NOT include an ID which matches the server name
[Tue Oct 05 12:00:27.586616 2021] [ssl:warn] [pid 20640:tid 584] AH01909: localhost:444:0 server certificate does NOT include an ID which matches the server name
PHP Warning:  PHP Startup: Unable to load dynamic library 'sqlite3' (tried: D:/wampstack-8.0.10-1/php/ext\\sqlite3 (The specified module could not be found), D:/wampstack-8.0.10-1/php/ext\\php_sqlite3.dll (The specified module could not be found)) in Unknown on line 0
[Tue Oct 05 12:00:27.614030 2021] [mpm_winnt:notice] [pid 20640:tid 584] AH00354: Child: Starting 64 worker threads.

我尝试在 php.ini 中取消注释 extension=sqlite3,但没有成功。我觉得这是路径问题,但不知道如何解决。任何帮助将不胜感激。

【问题讨论】:

    标签: apache wamp


    【解决方案1】:

    在您的 httpd.conf 文件中添加以下行:

    LoadModule php_module "C:/PHP/php8apache2_4.dll"
    PHPIniDir "C:/PHP"
    LoadFile "C:/PHP/libssh2.dll"
    LoadFile "C:/PHP/libsqlite3.dll"
    

    并在您的 php.ini 文件中的 extension_dir 设置中添加完整路径:

    extension_dir = "C:\PHP\ext"
    

    【讨论】:

      猜你喜欢
      • 2021-08-27
      相关资源
      最近更新 更多