In CentOS I have a compiled version of PHP but it is missing IMAP module. Is it possible to add that module without re-compiling php?
In CentOS I have a compiled version of PHP but it is missing IMAP module. Is it possible to add that module without re-compiling php?
Yes, you can just download the source of your current version, untar it, go the the ext/imap directory of the untared source then run:
You might need to run ./configure with some options specifiying the imap libraries used like:
After you compiled the module you should located it under ext/imap/modules, it should be named imap.so like ext/imap/modules/imap.so. You need to move this further to the extension_dir directory that you can get by running
php -i | grep extension_dir
or by createing a php file that will say<?php phpinfo(); ?>
and run it from the web interface after which search for extension_dir on the result page.After you've moved the module file you'll need to add a line in the php.ini file(or create an .ini file in the additional .ini files directory) that will say:
After that you'll need to restart your web-server or php-fpm service in case you're using php-fpm.