简体   繁体   中英

PHP Warning: Module 'json' already loaded

While executing my PHP code in editor (Eclipse), I am getting this error:

PHP Warning: Module 'json' already loaded in Unknown on line 0.

What's the problem here, and how do I fix it?

What version of PHP are you running? Have you recently upgraded from an older version?

The JSON module only became a standard part of PHP in v5.2; prior to that you would have had to added the PECL JSON module into it yourself.

If you've upgraded to 5.2 or 5.3, but you've still got an old config which is trying to add the PECL JSON module, then it will conflict with the JSON module that is now built into PHP.

Try to find where you're including the PECL module and remove it. Your JSON functions should continue to work as before.

php.ini中搜索行extension=json.so并删除或更改为;extension=json.so

有时您需要检查文件夹php.d (在我的情况下是 centos)而不是检查文件20-json.ini

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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