简体   繁体   English

Windows XP上的php扩展名

[英]php extension on windows xp

I've installed php on my xp, but failed to add an extension to mysql 我在xp上安装了php,但是无法向mysql添加扩展名

Here is what I did in php.ini: 这是我在php.ini中所做的:

[PHP_MYSQL]
extension=php_mysql.dll

and there is such a file in ext/ ext/有这样的文件

but when I look into phpinfo() , only to find that mysql extension is still not added. 但是当我查看phpinfo() ,才发现仍然没有添加mysql扩展。

What have I did wrongly? 我做错了什么?

[PHP_MYSQL] [PHP_MYSQL]

wouldn't this bit cause problems? 这不会引起问题吗? guessing. 猜测。

In your php.ini file do the following: 在您的php.ini文件中,执行以下操作:

extension=ext/php_mysql.dll

This should exist under the [PHP] configuration section, not [PHP_MYSQL] . 它应该在[PHP]配置部分下,而不是[PHP_MYSQL]

Are you using Apache? 您在使用Apache吗? If so, check php.ini in apache\\bin as this may be the ini file is use. 如果是这样,请检查apache \\ bin中的php.ini,因为这可能是ini文件正在使用。

As Evgeniy Savichev pointed out, the name of the file being parsed is displayed in phpinfo under 'Loaded Configuration File' 正如Evgeniy Savichev指出的那样,要解析的文件的名称显示在phpinfo中的“已加载的配置文件”下

Make sure that you have the mysql client DLLs installed and somewhere on %PATH%. 确保您已安装mysql客户端DLL,并且已将其安装在%PATH%上。 Also, you can use a tool like depwalker to load the php_mysql.dll and see what the missing dynamic linkage is. 另外,您可以使用depwalker之类的工具来加载php_mysql.dll,并查看缺少的动态链接是什么。

为避免配置问题,我将安装XAMPP( http://www.apachefriends.org/en/xampp.html ),它会安装php,apache和mysql并将其全部配置为可以正常工作的服务器安装。

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

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