apache和php都正常工作,但是就是无法连接数据库,测试的时候结果是“页面无法显示……”
php.ini中打开了下面几个模块:
    extension=php_curl.dll
    extension=php_gd2.dll
    extension=php_mbstring.dll
    extension=php_mysql.dll
    extension=php_xmlrpc.dll
error日志中显示:
[Sun Oct 07 12:57:24 2012] [notice] Parent: child process exited with status 255 -- Restarting.
[Sun Oct 07 12:57:24 2012] [notice] Apache/2.2.22 (Win32) PHP/5.2.4 configured -- resuming normal operations
[Sun Oct 07 12:57:24 2012] [notice] Server built: Jan 28 2012 11:16:39
[Sun Oct 07 12:57:24 2012] [notice] Parent: Created child process 5824
[Sun Oct 07 12:57:24 2012] [notice] Child 5824: Child process is running
[Sun Oct 07 12:57:24 2012] [notice] Child 5824: Acquired the start mutex.
[Sun Oct 07 12:57:24 2012] [notice] Child 5824: Starting 64 worker threads.
[Sun Oct 07 12:57:24 2012] [notice] Child 5824: Starting thread to listen on port 80.求高手解答,网上都搜遍了,还是没有解决问题!

解决方案 »

  1.   

    是不是少配置了php的安装目录
      

  2.   

    本帖最后由 xuzuning 于 2012-10-07 18:55:53 编辑
      

  3.   

    你连接不了数据库,就贴那部分代码和log, 这让人怎么判断?
      

  4.   

    用$sql=mysql-connect(“localhost”,“root”,“”) or die(“链接错误”); 测试一下    实在不行   就重新安装
      

  5.   

    你的php版本是多少的?如果是php5.2的话,需要把三个文件放入c:/windows 下
     
    详细请看:http://www.phpk8.com/article/f4/148.html
      

  6.   

    这个问题   有很多因素   有的sql语句  有可能写不对   也有可能用的 编码格式不对  也有可能你的配置文件  没有配好
      

  7.   

    火狐显示:连接被重置,载入页面时到服务器的连接被重置。
    chrome显示:无法显示此网页,与 127.0.0.1 的连接已中断。
    不像是配置方面的问题吧?
      

  8.   

    顶13楼,这问题应该是mysql服务没开启导致的
      

  9.   

    谢谢各位网友的关注,采用这个帖子中的第一个方法解决了,给大家分享一下:http://blog.csdn.net/bakeloar/article/details/7417545