简体   繁体   中英

How to use Apple's php 5.3 with MAMP

There is a bug in php 5.3 with the iconv module. Apple applied a patch for their version of php. However, MAMP didn't include this patch and is thus unusable with Zend Framework (for example).

I tried to include Apple's version of php 5.3 into the MAMP's httpd.conf, but ran into problems with symbols which could not be found. Does anyone know of a proper way to use MAMP with php 5.3 /w iconv? Is recompiling or linking apple's version an option?

Just rename the php directories in /Applications/MAMP/bin/php Duplicate php 5.3 directory and rename it to the same ver number of 5.2, and it works. :d

I'm not sure this leave a whole lot of value in the MAMP, but you probably are best served compiling your own php and apache.

http://fabien.potencier.org/article/37/php-5-3-0-on-mac-os-10-6-snow-leopard

There is a discussion of this issue here: iconv_strlen function causing execution timeout, running on MAMP

The basic solution is either to downgrade your MAMP to version 1.9.4 which is the last stable version as far as “iconv” is concerned. Or you can use any version of MAMP from 1.9.5 onwards but switch the PHP version from the MAMP preferences from 5.3 to 5.2.

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