Hi I am trying to get PHP-Mcrypt installed on Centos 5 the only file i could find is libmcrypt. is this right or is there other files i need to download? I thort there was a how to that covered this but cannot find it. Any help would be appreciated Colin Apache/2.2.3 (CentOS) PHP 5.1.6
You can do this using yum and all dependencies will be resolved. Use the rpmforge repo Code: rpm -Uhv http://apt.sw.be/packages/rpmforge-release/rpmforge-release-0.3.6-1.el5.rf.i386.rpm yum install libmcrypt
Thanks for the reply Topdog. I am using virtualmin to administer the server and according to this software it is installed but not enabled (needs dynamic loading ) I have tried adding extension=libmcrypt.so to php.ini but still nothing shows up in phpinfo(). I have restarted apache and even done a reboot. What am i doing wrong?? Colin
ok changed that and restarted but still nothing. When i get back to the server i will uninstall the package and reinstall. Should the code below also update the php.ini file or do i have to do that bit myself? Code: rpm -Uhv http://apt.sw.be/packages/rpmforge-release/rpmforge-release-0.3.6-1.el5.rf.i386.rpm yum install libmcrypt Thanks Colin
That just installs the library you need to install the php extension which you can get from the site i linked. If you install the rpm you do not need to modify anything as the rpm installs a file in /etc/php.d which loads the extension.
I installed mysql and mcrypt: [tyu@vh20 lib]$ cat /etc/php.d/ dbase.ini mhash.ini mysql.ini pdo_mysql.ini mcrypt.ini mysqli.ini pdo.ini pdo_sqlite.ini But I still see: [Sun Apr 12 12:07:37 2009] [error] [client 10.13.8.22] PHP Fatal error: Call to undefined function mysql_pconnect() in /home/wr_webroot/framework/Webroot/DAO/Dispatcher.php on line 43 Any idea ?
You can create the following PHP file... PHP: <?php phpinfo(); ?> ... and call it in a browser. Do you see MySQL enabled there?
I restarted Apache. First I saw: PHP Warning: PHP Startup: Unable to load dynamic library '/usr/local/lib/php/extensions/no-debug-non-zts-20060613/mcrypt.so' - /usr/local/lib/php/extensions/no-debug-non-zts-20060613/mcrypt.so: cannot open shared object file: No such file or directory in Unknown on line 0 So I symlinked /usr/lib/php/modules/mcrypt.so to /usr/local/lib/php/extensions/no-debug-non-zts-20060613 But then I saw: PHP Warning: PHP Startup: mcrypt: Unable to initialize module\nModule compiled with module API=20050922, debug=0, thread-safety=0\nPHP compiled with module API=20060613, debug=0, thread-safety=0\nThese options need to match\n in Unknown on line 0 How do I install 20060613 mcrypt ?
It looks like your installed mcrypt was built from source as well as rpm and one is linked to a different php version