I'm having a problem running a command in php using APC in my mac. In the MAMP Pro i have it on but looks like my mac is not using MAMP's php but using osx'.
Any idea about how to tell my mac to use MAMP Pro instead of OSX' php.ini?
The MAMP Pro
PHP
executable should be located in /Applications/MAMP/bin/php/php5.x.x/bin/
.
The OSX
PHP
is located in /usr/bin/php
and /usr/bin
is in PATH
variable by default.
One way to make OSX
use MAMP
PHP
is to add /Applications/MAMP/bin/php/php5.x.x/bin/
to your PATH
variable (before /usr/bin
):
Simply edit ~/.profile
(ie. open Terminal.app
, type vim ~/.profile
) and add the following line to end of the file:
export PATH=/Applications/MAMP/bin/php/php5.x.x/bin/:$PATH
Note that you should replace x
s in php5.x.x
with the MAMP Pro
PHP
version.