Help PHP/Apache, MAMP

Discussion in 'Web Design and Development' started by macDonalds, Mar 12, 2009.

  1. macDonalds macrumors 6502

    Joined:
    Jun 8, 2007
    #1
    Let me preface this with: I'm coming from Windows, I know little about the unix dir structure and command line.

    I wanted to get Apache, PHP, and MySQL up and running. I understand maybe 2/3 if not all 3 are installed on the latest version of Mac Leopard - great. So I recently got a Macbook Pro and I'm trying to learn these technologies. I decide that I want to get the latest version of PHP. Long story short - I installed Macports, edited various configuration files from multiple Google searches and finally have tried MAMP; the problem is this: "php -v" at the command line shows version 5.2.9, which is the latest. However, phpinfo() shows 5.2.6.

    Any idea why this is happening and how I can correct it? Thanks.
     
  2. HomeBru Studios macrumors member

    HomeBru Studios

    Joined:
    Jun 4, 2008
    #2
    Mac OS comes with PHP as part of the standard package.
    MAMP installs its own version.
    You're "php -v" command is probably looking at the OS' copy of PHP and not the MAMP copy.

    Type 'which PHP' in a terminal window to show you where your OS copy is living (mine is in "/usr/bin/").
    MAMP's copy lives in "Applications > MAMP > bin > php5 > bin"
     

Share This Page