Linux的PHP的致命错误:调用未定义的函数mysqli_connect() [英] Linux PHP Fatal error: Call to undefined function mysqli_connect()

查看:1750
本文介绍了Linux的PHP的致命错误:调用未定义的函数mysqli_connect()的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有关于连接它给这个错误的数据库问题

I have a problem regarding connecting the database it is giving this error

Fatal error: Call to undefined function mysqli_connect()

其中,我花过去的4小时试图想通了,我已经做了这些步骤:

Which, I have spend the past 4 hours trying to figured out and I already did these steps:


  1. 更改扩展名= mysql.so和延长= mysqli.so

  2. 的extension_dir = / php.ini文件路径

  3. 经过哪些模块被加载或PHP安装 - 米

我只是用INFOPHP()的引擎收录SORRY,我的网站在其下运行用户名和密码保护因为私立大学服务器。

I JUST PUT MY INFOPHP() IN PASTEBIN SORRY, MY WEBSITE IS RUNNING UNDER USERNAME AND PASSWORD PROTECTING BECAUSE IS A PRIVATE UNIVERSITY SERVER..

http://pastebin.com/dKKdwWTb

我也不太清楚还有什么我可以做,以防万一我已经添加了链接粘贴斌为我的php.ini文件

I am not too sure what else I can do about, just in case I have added the link for paste bin for my php.ini file

http://pastebin.com/QNK6mGqV

好吧,我希望有人能看到什么,我已经能够看到并可以帮助我。

Well, I hope someone could see what I have been able to see and could help me out.

推荐答案

检查网页phpinfo()函数的输出。 PHP -m是CLI,您mod_apache可能使用一个不同的php.ini比CLI之一。

Check output of phpinfo() in web page. php -m is for cli, your mod_apache probably be using a different php.ini than the cli one.

在看到你的网页的phpinfo()我们可以看到我的假设是正确的。你真的使用了不同的php.ini为你的Apache和它的mysqli扩展未启用。结果
在phpinfo()函数的输出,你必须在哪里可以找到php.ini文件中的细节,并在那里是扩展目录。

After seeing your web phpinfo() we can see my assumption is correct. You really are using a different php.ini for your apache, and in it the mysqli extension is not enabled.
in the phpinfo() output you have the details on where to find the php.ini file, and where is the extension directory.

干杯。

这篇关于Linux的PHP的致命错误:调用未定义的函数mysqli_connect()的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆