Ad

PHP Warning: Module 'modulename' Already Loaded In Unknown On Line 0

- 1 answer

Running Mac OS X Yosemite with OS X Server, every time I run PHP commands in Terminal I get these 2 lines...

PHP Warning:  Module 'mcrypt' already loaded in Unknown on line 0
PHP Warning:  Module 'pgsql' already loaded in Unknown on line 0

Solutions I've seen (including on StackOverflow) suggest looking for duplicates of the lines loading those extensions in php.ini which I've checked & ruled out.

Ad

Answer

Solved. Running php -m reveals that, unlike in previous versions of OS X, the PHP in Yosemite has mcrypt & pgsql compiled in. Removing the directives loading those as extensions eliminated the problem.

Ad
source: stackoverflow.com
Ad