dongma2388 2014-09-22 13:10
浏览 70

Xampp Apache ssl错误 - 无法连接到数据库

I recently installed a local webserver (XAMPP) so I could work with the Laravel PHP framework. I successfully installed xampp and changed the Apache httpd.conf to listen to port 8080.

I also managed to get Laravel up and running: enter image description here

But I noticed I couldn't connect to the database, the page would just load forever without showing me any errors. Same thing when I ran this simple code:

<?php
error_reporting(E_ALL);

$host = 'localhost:8080';
$name = 'test';
$user = 'root';
$pass = '';

mysqli_connect($host, $user, $pass, $name) or die ("Oops");

This happens when I start Apache:

enter image description here

In the Apache error log I found this:

[Mon Sep 22 14:47:29.969486 2014] [ssl:warn] [pid 5044:tid 388] AH01909: www.example.com:443:0 server certificate does NOT include an ID which matches the server name
[Mon Sep 22 14:47:29.996504 2014] [core:warn] [pid 5044:tid 388] AH00098: pid file C:/xampp/apache/logs/httpd.pid overwritten -- Unclean shutdown of previous Apache run?
[Mon Sep 22 14:47:30.087565 2014] [ssl:warn] [pid 5044:tid 388] AH01909: www.example.com:443:0 server certificate does NOT include an ID which matches the server name
[Mon Sep 22 14:47:30.117584 2014] [mpm_winnt:notice] [pid 5044:tid 388] AH00455: Apache/2.4.10 (Win32) OpenSSL/1.0.1i PHP/5.5.15 configured -- resuming normal operations
[Mon Sep 22 14:47:30.117584 2014] [mpm_winnt:notice] [pid 5044:tid 388] AH00456: Apache Lounge VC11 Server built: Jul 17 2014 11:50:08
[Mon Sep 22 14:47:30.117584 2014] [core:notice] [pid 5044:tid 388] AH00094: Command line: 'c:\\xampp\\apache\\bin\\httpd.exe -d C:/xampp/apache'
[Mon Sep 22 14:47:30.119586 2014] [mpm_winnt:notice] [pid 5044:tid 388] AH00418: Parent: Created child process 2608
[Mon Sep 22 14:47:30.488831 2014] [ssl:warn] [pid 2608:tid 412] AH01909: www.example.com:443:0 server certificate does NOT include an ID which matches the server name
[Mon Sep 22 14:47:30.605909 2014] [ssl:warn] [pid 2608:tid 412] AH01909: www.example.com:443:0 server certificate does NOT include an ID which matches the server name
[Mon Sep 22 14:47:30.637930 2014] [mpm_winnt:notice] [pid 2608:tid 412] AH00354: Child: Starting 150 worker threads.

I think this is the reason that I can't connect to the database. But I can't seem to figure it out. I've searched a lot before asking this question. I hope somebody could help me out.

  • 写回答

0条回答 默认 最新

    报告相同问题?

    悬赏问题

    • ¥60 版本过低apk如何修改可以兼容新的安卓系统
    • ¥25 由IPR导致的DRIVER_POWER_STATE_FAILURE蓝屏
    • ¥50 有数据,怎么建立模型求影响全要素生产率的因素
    • ¥50 有数据,怎么用matlab求全要素生产率
    • ¥15 TI的insta-spin例程
    • ¥15 完成下列问题完成下列问题
    • ¥15 C#算法问题, 不知道怎么处理这个数据的转换
    • ¥15 YoloV5 第三方库的版本对照问题
    • ¥15 请完成下列相关问题!
    • ¥15 drone 推送镜像时候 purge: true 推送完毕后没有删除对应的镜像,手动拷贝到服务器执行结果正确在样才能让指令自动执行成功删除对应镜像,如何解决?