简体   繁体   English

使用Mac OS X下Macports安装的mySql5 + php5 + apache2的未定义mysql函数

[英]Undefined mysql functions using mySql5 + php5 + apache2 installed by macports under mac os x

I've installed mySql5 using macports and did manage to run the mysql server. 我已经使用macports安装了mySql5,并设法运行了mysql服务器。 but from some reason all mySql related functions like mysql_connect return an error message saying "a call to undefined function...." under php5. 但是由于某种原因,所有与mySql相关的函数(如mysql_connect)都在php5下返回一条错误消息,提示“对未定义函数的调用...。”。

Here is partial mysqlnd section taken from the phpinfo report: 这是取自phpinfo报告的部分mysqlnd部分:

mysqlnd enabled
Version  mysqlnd 5.0.5-dev - 081106 - $Revision: 289630 $
Command buffer size  4096
Read buffer size  32768
Read timeout  31536000
Collecting statistics  Yes
Collecting memory statistics  Yes

Client statistics 
bytes_sent  0
bytes_received  0
packets_sent  0
packets_received  0
protocol_overhead_in  0
protocol_overhead_out  0
bytes_received_ok_packet  0 

Does anyone know how to solve this issue? 有谁知道如何解决这个问题?

Thanks 谢谢

Did you also install php5 with the mysql variant? 您是否还安装了带有mysql变体的php5?

sudo port install php5 +mysql or soemthing liek that... i havent installed the php port in awhile. sudo port install php5 +mysql PHP5 sudo port install php5 +mysql或类似的东西...我还没有安装PHP端口在一段时间。 :-) :-)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM