Xampp警告:模块“openssl”已经在第0行加载

时间:2021-05-15 13:11:52

I have installed Xampp on windows 7. When I try to run code I get the error

我已经在windows 7上安装了Xampp。当我试图运行代码时,我得到了错误

Warning: Module 'openssl' already loaded in line 0

警告:模块“openssl”已经在第0行加载

This is the same code I have run on the pc before, all I have done is reinstalled Win 7 and a clean install of XAMPP

这是我以前在pc上运行的代码,我所做的就是重新安装win7和XAMPP

4 个解决方案

#1


59  

You seem to have the line

你似乎有台词

extension=php_openssl.dll

twice in your php.ini file and/or subfiles.

在php的两倍。ini文件和/或子文件。

You need to find all relevant php.ini files in your xampp directory and remove or comment out one of the module directives like this:

您需要找到所有相关的php。在xampp目录中的ini文件,并删除或注释其中一个模块指令如下:

;extension=php_openssl.dll

After a server restart, this should solve it.

服务器重新启动后,应该可以解决这个问题。

#2


12  

  1. Open xampp -> PHP -> php.ini

    打开xampp -> PHP -> PHP .ini

  2. Open the file php.ini in any text editor

    php打开文件。任何文本编辑器中的ini

  3. Press CTRL + F and Search for openssl

    按CTRL + F,搜索openssl

  4. Comment the line extension=php_openssl.dll by placing a semi-colon at the beginning: ;extension=php_openssl.dll

    评论= php_openssl线延伸。将分号放在开头:;extension=php_openssl.dll的dll中

Note : If you want to enable it again remove the semicolon

注意:如果要重新启用分号,请删除分号

#3


0  

I had the same problem and there were not multiple extension=php_openssl.dll in my case. The reason was because I had two copies of apache for some reasons, but I only used one.

我遇到了同样的问题,并且没有多个扩展=php_openssl。dll在我的例子中。原因是由于某些原因,我有两个apache的副本,但是我只使用了一个。

I deleted the copy and changed the environment variable Path and OPENSSL_CONF to point to the correct webserver.

我删除了副本,并更改了环境变量路径和OPENSSL_CONF以指向正确的webserver。

After restarting the webserver it worked! Make sure to restart all terminals and CMDs, otherwise the old environment variables are used and the error persists.

在重新启动webserver之后,它工作了!请确保重新启动所有终端和CMDs,否则将使用旧的环境变量,错误将继续存在。

#4


0  

reinstall the xampp and give new location to the required bar in composor installation.

重新安装xampp,并在安装过程中为所需的bar提供新的位置。

#1


59  

You seem to have the line

你似乎有台词

extension=php_openssl.dll

twice in your php.ini file and/or subfiles.

在php的两倍。ini文件和/或子文件。

You need to find all relevant php.ini files in your xampp directory and remove or comment out one of the module directives like this:

您需要找到所有相关的php。在xampp目录中的ini文件,并删除或注释其中一个模块指令如下:

;extension=php_openssl.dll

After a server restart, this should solve it.

服务器重新启动后,应该可以解决这个问题。

#2


12  

  1. Open xampp -> PHP -> php.ini

    打开xampp -> PHP -> PHP .ini

  2. Open the file php.ini in any text editor

    php打开文件。任何文本编辑器中的ini

  3. Press CTRL + F and Search for openssl

    按CTRL + F,搜索openssl

  4. Comment the line extension=php_openssl.dll by placing a semi-colon at the beginning: ;extension=php_openssl.dll

    评论= php_openssl线延伸。将分号放在开头:;extension=php_openssl.dll的dll中

Note : If you want to enable it again remove the semicolon

注意:如果要重新启用分号,请删除分号

#3


0  

I had the same problem and there were not multiple extension=php_openssl.dll in my case. The reason was because I had two copies of apache for some reasons, but I only used one.

我遇到了同样的问题,并且没有多个扩展=php_openssl。dll在我的例子中。原因是由于某些原因,我有两个apache的副本,但是我只使用了一个。

I deleted the copy and changed the environment variable Path and OPENSSL_CONF to point to the correct webserver.

我删除了副本,并更改了环境变量路径和OPENSSL_CONF以指向正确的webserver。

After restarting the webserver it worked! Make sure to restart all terminals and CMDs, otherwise the old environment variables are used and the error persists.

在重新启动webserver之后,它工作了!请确保重新启动所有终端和CMDs,否则将使用旧的环境变量,错误将继续存在。

#4


0  

reinstall the xampp and give new location to the required bar in composor installation.

重新安装xampp,并在安装过程中为所需的bar提供新的位置。